From a6fceffd5628369977c9535539dc749dd4aab85c Mon Sep 17 00:00:00 2001 From: Marcel van der Veldt Date: Wed, 11 May 2022 22:00:36 +0200 Subject: [PATCH] add image helper --- music_assistant/helpers/images.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/music_assistant/helpers/images.py b/music_assistant/helpers/images.py index 8ab2ea99..1dec4976 100644 --- a/music_assistant/helpers/images.py +++ b/music_assistant/helpers/images.py @@ -38,6 +38,9 @@ async def get_image_url( for img in media_item.metadata.images: if img.type == img_type: return img.url + if img_type == ImageType.THUMB and img.type == ImageType.EMBEDDED_THUMB: + if file_prov := mass.music.get_provider("filesystem"): + return await file_prov.get_embedded_image(img.url) # retry with track's album if media_item.media_type == MediaType.TRACK and media_item.album: -- 2.34.1