ftintitle: check artist_sort for null (fix #418)

This commit is contained in:
Adrian Sampson 2013-10-14 21:11:40 -07:00
parent e430b61e7d
commit 8e2c1bbe68
2 changed files with 5 additions and 2 deletions

View file

@ -49,13 +49,15 @@ def contains_feat(title):
def update_metadata(item, feat_part):
"""Choose how to add new artists to the title and write the new
"""Choose how to add new artists to the title and set the new
metadata. Also, print out messages about any changes that are made.
"""
# In all cases, update the artist fields.
ui.print_(u'artist: {0} -> {1}'.format(item.artist, item.albumartist))
item.artist = item.albumartist
item.artist_sort, _ = split_on_feat(item.artist_sort) # Strip featured.
if item.artist_sort:
# Just strip the featured artist from the sort name.
item.artist_sort, _ = split_on_feat(item.artist_sort)
# Only update the title if it does not already contain a featured
# artist.

View file

@ -8,6 +8,7 @@ Little fixes:
* :doc:`/plugins/missing`: Avoid a possible error when an album's
``tracktotal`` field is missing.
* :doc:`/plugins/ftintitle`: Fix an error when the sort artist is missing.
1.3.1 (October 12, 2013)
------------------------