Merge code cleanup
This commit is contained in:
parent
caee30f37c
commit
a705794a91
|
@ -94,7 +94,7 @@ class Spotify(Plugin):
|
||||||
cache['tracks'][link_id] = cachedTrack
|
cache['tracks'][link_id] = cachedTrack
|
||||||
self.saveCache(cache)
|
self.saveCache(cache)
|
||||||
|
|
||||||
if 'id' in cachedTrack and cachedTrack['id'] != "0":
|
if cachedTrack.get('id', "0") != "0":
|
||||||
return generateTrackItem(dz, cachedTrack['id'], bitrate)
|
return generateTrackItem(dz, cachedTrack['id'], bitrate)
|
||||||
|
|
||||||
raise TrackNotOnDeezer(f"https://open.spotify.com/track/{link_id}")
|
raise TrackNotOnDeezer(f"https://open.spotify.com/track/{link_id}")
|
||||||
|
@ -213,7 +213,7 @@ class Spotify(Plugin):
|
||||||
cache['tracks'][track['id']] = cachedTrack
|
cache['tracks'][track['id']] = cachedTrack
|
||||||
self.saveCache(cache)
|
self.saveCache(cache)
|
||||||
|
|
||||||
if 'id' in cachedTrack and cachedTrack['id'] != "0":
|
if cachedTrack.get('id', "0") != "0":
|
||||||
trackAPI = dz.api.get_track(cachedTrack['id'])
|
trackAPI = dz.api.get_track(cachedTrack['id'])
|
||||||
|
|
||||||
deezerTrack = None
|
deezerTrack = None
|
||||||
|
|
Loading…
Reference in New Issue