mirror of
https://github.com/BillyOutlast/metadata-scrapers.git
synced 2026-07-01 19:54:34 -04:00
add edgecase for when matched file is in a previous revision of a post
This commit is contained in:
committed by
feederbox826
parent
425177b402
commit
d25cca4a47
@@ -211,6 +211,10 @@ def parseAPI(scene, hash):
|
||||
scene['type'] = "video"
|
||||
contentfiles = videofiles
|
||||
#get video or image total and content position
|
||||
if contentfiles is None:
|
||||
log.debug("API returned response but could not match any file. Probably because the file is in a previous revision of the post.")
|
||||
scene['total'] = 0
|
||||
return result, scene
|
||||
for i, file in enumerate(contentfiles):
|
||||
if hash in file['path']:
|
||||
scene['part'] = i + 1
|
||||
|
||||
Reference in New Issue
Block a user