[vk] get URLs from *_src entries (#2535)

https://github.com/mikf/gallery-dl/issues/2535#issuecomment-1166566986
This commit is contained in:
Mike Fährmann
2022-06-27 10:24:35 +02:00
parent 54525d2e21
commit 367a491128

View File

@@ -40,12 +40,12 @@ class VkExtractor(Extractor):
continue
try:
photo["url"], photo["width"], photo["height"] = photo[size]
_, photo["width"], photo["height"] = photo[size]
except ValueError:
# photo without width/height entries (#2535)
photo["url"] = photo[size + "src"]
photo["width"] = photo["height"] = 0
photo["url"] = photo[size + "src"]
photo["id"] = photo["id"].rpartition("_")[2]
photo.update(data)