Fix #214: Do not crash on flac import if musicbrainz tags are missing
This commit is contained in:
parent
54008aa37c
commit
01ea6562a6
3 changed files with 13 additions and 1 deletions
|
|
@ -30,7 +30,7 @@ def get_id3_tag(f, k):
|
|||
|
||||
def get_flac_tag(f, k):
|
||||
try:
|
||||
return f.get(k)[0]
|
||||
return f.get(k, [])[0]
|
||||
except (KeyError, IndexError):
|
||||
raise TagNotFound(k)
|
||||
|
||||
|
|
@ -158,6 +158,9 @@ CONF = {
|
|||
'musicbrainz_recordingid': {
|
||||
'field': 'musicbrainz_trackid'
|
||||
},
|
||||
'test': {
|
||||
'field': 'test'
|
||||
},
|
||||
}
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue