From 810737242cb2a21cf14de4704ffa93fbef67ed64 Mon Sep 17 00:00:00 2001 From: James Barnsley Date: Sun, 4 Sep 2022 11:33:25 +1200 Subject: [PATCH] Removing item from store when loading fails --- src/js/services/spotify/actions.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/js/services/spotify/actions.js b/src/js/services/spotify/actions.js index 317fe346..474601fe 100755 --- a/src/js/services/spotify/actions.js +++ b/src/js/services/spotify/actions.js @@ -1169,6 +1169,7 @@ export function getAlbum(uri, { full, forceRefetch } = {}) { } }, (error) => { + dispatch(coreActions.removeItem(uri)); dispatch(coreActions.handleException( 'Could not load album', error, @@ -1414,6 +1415,7 @@ export function getPlaylist(uri, options = {}) { } }, (error) => { + dispatch(coreActions.removeItem(uri)); dispatch(coreActions.handleException( 'Could not load playlist', error,