From 1e7301740efefd20b22e23f0142e7e0a4a7d267c Mon Sep 17 00:00:00 2001 From: Brent Vollebregt Date: Mon, 25 Mar 2024 23:38:22 +1300 Subject: [PATCH] #16 Support accounts with empty playlists --- .vscode/settings.json | 2 +- src/components/PlaylistSelection.tsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 0aeb337..ad2fa71 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -3,6 +3,6 @@ "editor.rulers": [100], "editor.tabSize": 2, "editor.codeActionsOnSave": { - "source.fixAll.tslint": true + "source.fixAll.tslint": "explicit" } } diff --git a/src/components/PlaylistSelection.tsx b/src/components/PlaylistSelection.tsx index bd7bc5b..eda1cbe 100644 --- a/src/components/PlaylistSelection.tsx +++ b/src/components/PlaylistSelection.tsx @@ -117,7 +117,8 @@ const PlaylistSelection: React.FunctionComponent = (props: IProps) => { }} > - {playlist.images.length > 0 && ( + {/* Spotify has recently changed their responses - playlist.images is now nullable */} + {playlist.images !== null && playlist.images.length > 0 && (