diff --git a/headphones/importer.py b/headphones/importer.py index 4730a8c7..c02f508f 100644 --- a/headphones/importer.py +++ b/headphones/importer.py @@ -600,6 +600,17 @@ def addReleaseById(rid, rgid=None): newValueDict['IncludeExtras'] = 1 newValueDict['Extras'] = headphones.CONFIG.EXTRAS + if 'title' in release_dict: + newValueDict['LatestAlbum'] = release_dict['title'] + elif 'rg_title' in release_dict: + newValueDict['LatestAlbum'] = release_dict['rg_title'] + + if 'date' in release_dict: + newValueDict['ReleaseDate'] = release_dict['date'] + + if rgid: + newValueDict['AlbumID'] = rgid + myDB.upsert("artists", newValueDict, controlValueDict) elif not artist_exists and not release_dict: