From d43dc3f3dc8eae82060f3f70651b3d1fd3bc3bef Mon Sep 17 00:00:00 2001 From: Erica Date: Sun, 21 Nov 2021 01:46:40 +0000 Subject: [PATCH] Fixed error when no temporary album art present --- bin/miniplayer | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/bin/miniplayer b/bin/miniplayer index a9c76f1..c3b618d 100755 --- a/bin/miniplayer +++ b/bin/miniplayer @@ -366,13 +366,11 @@ class Player: return 1/(x+1)**2 - # Init thief - color_thief = ColorThief(self.album_art_loc) - - # Get palette + # Init thief and get palette try: + color_thief = ColorThief(self.album_art_loc) palette = color_thief.get_palette(color_count=COLOR_COUNT, quality=100) - except OSError: + except (OSError, FileNotFoundError): self.color_update_needed = True return