fix cache key
authorMarcel van der Veldt <m.vanderveldt@outlook.com>
Mon, 15 Apr 2024 21:43:51 +0000 (23:43 +0200)
committerMarcel van der Veldt <m.vanderveldt@outlook.com>
Mon, 15 Apr 2024 21:43:51 +0000 (23:43 +0200)
music_assistant/server/controllers/media/playlists.py

index a352aed6807c1c0f26c88df59f1f5b78130fc8a0..cafd7f576884251611e4233bb7f60611cd3d4dc1 100644 (file)
@@ -349,8 +349,9 @@ class PlaylistController(MediaControllerBase[Playlist]):
             # if this is a complete track object, pre-cache it as
             # that will save us an (expensive) lookup later
             if item.image and item.artist_str and item.album and provider.domain != "builtin":
-                cache_key = f"provider_item.track.{provider.lookup_key}.{item_id}"
-                await self.mass.cache.set(cache_key, item.to_dict())
+                await self.mass.cache.set(
+                    f"provider_item.track.{provider.lookup_key}.{item_id}", item.to_dict()
+                )
         # store (serializable items) in cache
         if cache_checksum != "no_cache":
             self.mass.create_task(