Fix #3, not publishing attached images
This commit is contained in:
pare
4f27e13c3a
commit
31a4b0a6e2
S'han modificat 1 arxius amb 3 adicions i 3 eliminacions
|
@ -422,16 +422,16 @@ if __name__ == '__main__':
|
|||
is_reply = True
|
||||
tweet_id = get_tweet_id(reply_id)
|
||||
|
||||
if len(entry.links) >= 2:
|
||||
if "media_content" in entry:
|
||||
|
||||
with_images = True
|
||||
images_list = []
|
||||
images = len(entry.links) - 1
|
||||
images = len(entry.media_content)
|
||||
|
||||
i = 0
|
||||
while i < images:
|
||||
|
||||
image_url = entry.links[i+1].href
|
||||
image_url = entry.media_content[i]['url']
|
||||
image_filename = write_image(image_url)
|
||||
images_list.append(image_filename)
|
||||
i += 1
|
||||
|
|
Loading…
Referencia en una nova incidència