Only catch KeyError when accessing JSON dict
This commit is contained in:
parent
f9d000e265
commit
437dd510d3
@ -71,7 +71,7 @@ class CamModelsIE(InfoExtractor):
|
|||||||
'format_id': str(format.get('videoWidth'))
|
'format_id': str(format.get('videoWidth'))
|
||||||
})
|
})
|
||||||
# If they change the JSON format, then fallback to parsing out RTMP links via regex.
|
# If they change the JSON format, then fallback to parsing out RTMP links via regex.
|
||||||
except:
|
except KeyError:
|
||||||
manifest_json = json.dumps(manifest)
|
manifest_json = json.dumps(manifest)
|
||||||
manifest_links = re.finditer(
|
manifest_links = re.finditer(
|
||||||
r'(?P<id>rtmp?:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#&//=]*))',
|
r'(?P<id>rtmp?:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#&//=]*))',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user