merge in fixes from mdecker

This commit is contained in:
Adrian Sampson 2011-04-03 12:22:13 -07:00
commit 67678ffcf4
2 changed files with 3 additions and 2 deletions

View file

@ -301,7 +301,9 @@ def track_distance(item, track_data, track_index=None, incl_artist=False):
dist_max += TRACK_TITLE_WEIGHT
# Track artist, if included.
if incl_artist:
# Attention: MB DB does not have artist info for all compilations,
# so only check artist distance if there is actually an artist in the MB track data
if incl_artist and 'artist' in track_data:
dist += string_dist(item.artist, track_data['artist']) * \
TRACK_ARTIST_WEIGHT
dist_max += TRACK_ARTIST_WEIGHT

View file

@ -532,7 +532,6 @@ def apply_choices(lib, copy, write, art, delete, progress):
# Only delete files that were actually moved.
if old_path not in new_paths:
os.remove(library._syspath(old_path))
os.remove(library._syspath(old_path))
# Update progress.
if progress: