[fansly] provide fallback URL for manifest downloads (#4401)
This commit is contained in:
@@ -86,12 +86,17 @@ class FanslyExtractor(Extractor):
|
|||||||
if "metadata" in location:
|
if "metadata" in location:
|
||||||
# manifest
|
# manifest
|
||||||
meta = location["metadata"]
|
meta = location["metadata"]
|
||||||
|
|
||||||
file["type"] = "video"
|
file["type"] = "video"
|
||||||
|
|
||||||
|
try:
|
||||||
|
fallback = (media["locations"][0]["location"],)
|
||||||
|
except Exception:
|
||||||
|
fallback = ()
|
||||||
|
|
||||||
files.append({
|
files.append({
|
||||||
"file": file,
|
"file": file,
|
||||||
"url": f"ytdl:{location['location']}",
|
"url": f"ytdl:{location['location']}",
|
||||||
# "_fallback": (media["locations"][0]["location"],),
|
"_fallback": fallback,
|
||||||
"_ytdl_manifest":
|
"_ytdl_manifest":
|
||||||
"dash" if mime == "application/dash+xml" else "hls",
|
"dash" if mime == "application/dash+xml" else "hls",
|
||||||
"_ytdl_manifest_cookies": (
|
"_ytdl_manifest_cookies": (
|
||||||
|
|||||||
Reference in New Issue
Block a user