Add a check for weird audio files, instead of crashing
This commit is contained in:
parent
a1a7c76dc9
commit
143bb0a5f3
@ -41,6 +41,9 @@ class MP3Parser(MutagenParser):
|
|||||||
if not meta:
|
if not meta:
|
||||||
return metadata
|
return metadata
|
||||||
for key in meta:
|
for key in meta:
|
||||||
|
if isinstance(key, tuple):
|
||||||
|
metadata[key[0]] = key[1]
|
||||||
|
continue
|
||||||
if not hasattr(meta[key], 'text'): # pragma: no cover
|
if not hasattr(meta[key], 'text'): # pragma: no cover
|
||||||
continue
|
continue
|
||||||
metadata[key.rstrip(' \t\r\n\0')] = ', '.join(map(str, meta[key].text))
|
metadata[key.rstrip(' \t\r\n\0')] = ', '.join(map(str, meta[key].text))
|
||||||
|
Loading…
Reference in New Issue
Block a user