[pinterest] support 'story_pin_music_block' blocks (#6421)

This commit is contained in:
Mike Fährmann
2024-11-05 13:57:25 +01:00
parent 0b3ddd01af
commit a9a9f3a180
2 changed files with 15 additions and 0 deletions

View File

@@ -122,6 +122,11 @@ class PinterestExtractor(Extractor):
media = self._extract_video(video)
media["media_id"] = video.get("id") or ""
elif type == "story_pin_music_block":
media = block["audio"]
media["url"] = media["audio_url"]
media["media_id"] = media.get("id") or ""
elif type == "story_pin_paragraph_block":
media = {"url": "text:" + block["text"],
"extension": "txt",