[newgrounds] add fallback for 'full_image_text' with empty 'src'

This commit is contained in:
Mike Fährmann
2025-08-16 15:44:34 +02:00
parent e599e3f0d6
commit 6d65c65647

View File

@@ -224,6 +224,10 @@ class NewgroundsExtractor(Extractor):
"width" : text.parse_int(full('width="', '"')),
"height" : text.parse_int(full('height="', '"')),
}
if not data["url"]:
data["url"] = extr('<a href="', '"')
index = data["url"].rpartition("/")[2].partition("_")[0]
data["index"] = text.parse_int(index)
data["_index"] = index