[instagram:stories] extract correct 'expires' dates (#8764)
This commit is contained in:
@@ -90,13 +90,11 @@ class InstagramExtractor(Extractor):
|
|||||||
post["count"] = len(files)
|
post["count"] = len(files)
|
||||||
yield Message.Directory, "", post
|
yield Message.Directory, "", post
|
||||||
|
|
||||||
if "date" in post:
|
|
||||||
del post["date"]
|
|
||||||
if reverse:
|
if reverse:
|
||||||
files.reverse()
|
files.reverse()
|
||||||
|
|
||||||
for file in files:
|
for file in files:
|
||||||
file.update(post)
|
file = {**post, **file}
|
||||||
|
|
||||||
if url := file.get("video_url"):
|
if url := file.get("video_url"):
|
||||||
if videos:
|
if videos:
|
||||||
@@ -301,7 +299,7 @@ class InstagramExtractor(Extractor):
|
|||||||
if "reshared_story_media_author" in item:
|
if "reshared_story_media_author" in item:
|
||||||
media["author"] = item["reshared_story_media_author"]
|
media["author"] = item["reshared_story_media_author"]
|
||||||
if "expiring_at" in item:
|
if "expiring_at" in item:
|
||||||
media["expires"] = self.parse_timestamp(post["expiring_at"])
|
media["expires"] = self.parse_timestamp(item["expiring_at"])
|
||||||
if "subscription_media_visibility" in item:
|
if "subscription_media_visibility" in item:
|
||||||
media["subscription"] = item["subscription_media_visibility"]
|
media["subscription"] = item["subscription_media_visibility"]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user