(back) Add location for albums

This commit is contained in:
2023-01-29 19:38:24 +01:00
parent cf8cd046f4
commit 7e0a791fbe
5 changed files with 56 additions and 20 deletions

View File

@@ -192,7 +192,8 @@ class ITunesParser:
'Avg Bit Rate': track['Bit Rate'],
'Min Bit Rate': track['Bit Rate'],
# 'Album Artist': '',
'Total Time': 0
'Total Time': 0,
'Location': ''
}
# Compute information
@@ -207,6 +208,8 @@ class ITunesParser:
self._albums[akey]['Play Count'] += play_count
self._albums[akey]['Total Time'] += total_time
self._albums[akey]['Location'] = os.path.dirname(track['Location'])
if self._albums[akey]['Min Bit Rate'] > track['Bit Rate']:
self._albums[akey]['Min Bit Rate'] = track['Bit Rate']