mirror of
https://github.com/arsenetar/dupeguru.git
synced 2025-03-10 05:34:36 +00:00
Fixed crash on iTunes library parsing when the "Location" element is missing in track data dictionary.
This commit is contained in:
parent
933474400c
commit
df9af9a796
@ -83,7 +83,10 @@ def get_itunes_songs(plistpath):
|
||||
for song_data in plist['Tracks'].values():
|
||||
if song_data['Track Type'] != 'File':
|
||||
continue
|
||||
song = ITunesSong(song_data)
|
||||
try:
|
||||
song = ITunesSong(song_data)
|
||||
except KeyError: # No "Location" or "Track ID" key in track
|
||||
continue
|
||||
if io.exists(song.path):
|
||||
result.append(song)
|
||||
return result
|
||||
|
Loading…
x
Reference in New Issue
Block a user