🛠️ Try harder to find a release date. Fixes #56

This commit is contained in:
Robert Honz
2024-03-19 14:53:03 +01:00
parent bc88b6fcac
commit 1e42f7c22d
+1 -1
View File
@@ -284,7 +284,7 @@ class Download:
def metadata_write(self, track: Track, path_file: str): def metadata_write(self, track: Track, path_file: str):
result: bool = False result: bool = False
release_date: str = ( release_date: str = (
track.album.release_date.strftime("%Y-%m-%d") if track.album and track.album.release_date else "" track.album.available_release_date.strftime("%Y-%m-%d") if track.album.available_release_date else track.album.release_date.strftime("%Y-%m-%d") if track.album.release_date else ""
) )
copy_right: str = track.copyright if hasattr(track, "copyright") and track.copyright else "" copy_right: str = track.copyright if hasattr(track, "copyright") and track.copyright else ""
isrc: str = track.isrc if hasattr(track, "isrc") and track.isrc else "" isrc: str = track.isrc if hasattr(track, "isrc") and track.isrc else ""