mirror of
https://github.com/beetbox/beets.git
synced 2025-12-06 16:42:42 +01:00
Add a check for valid data
This commit is contained in:
parent
c0e3a530f7
commit
fa822d6ab2
1 changed files with 3 additions and 1 deletions
|
|
@ -219,7 +219,9 @@ class SpotifyPlugin(MetadataSourcePlugin, BeetsPlugin):
|
||||||
album_data = self._handle_response(
|
album_data = self._handle_response(
|
||||||
requests.get, self.album_url + spotify_id
|
requests.get, self.album_url + spotify_id
|
||||||
)
|
)
|
||||||
self._log.debug('Album data: {}', album_data)
|
if album_data['name'] == "":
|
||||||
|
self._log.debug("Album removed from Spotify: {}", album_id)
|
||||||
|
return None
|
||||||
artist, artist_id = self.get_artist(album_data['artists'])
|
artist, artist_id = self.get_artist(album_data['artists'])
|
||||||
|
|
||||||
date_parts = [
|
date_parts = [
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue