Removing item from store when loading fails

This commit is contained in:
James Barnsley
2022-09-04 11:33:25 +12:00
parent b3dc8f896c
commit 810737242c

View File

@ -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,