From 4000651c785d08bfb8191f1dfb1f5079879adbe3 Mon Sep 17 00:00:00 2001 From: ririxi Date: Fri, 1 Dec 2023 22:02:44 +0100 Subject: [PATCH] feat: remove compatibility `track` property --- globals.d.ts | 4 ---- jsHelper/spicetifyWrapper.js | 4 ---- 2 files changed, 8 deletions(-) diff --git a/globals.d.ts b/globals.d.ts index ed6a275a45..7dfcccc6a4 100644 --- a/globals.d.ts +++ b/globals.d.ts @@ -190,10 +190,6 @@ declare namespace Spicetify { playbackId: string; sessionId: string; signals?: any[]; - /** - * @deprecated Use `item` instead. This will be removed in the future. - */ - track: PlayerTrack; }; type PlayerContext = { uri: string; diff --git a/jsHelper/spicetifyWrapper.js b/jsHelper/spicetifyWrapper.js index 616a46d9b9..d0a9198723 100644 --- a/jsHelper/spicetifyWrapper.js +++ b/jsHelper/spicetifyWrapper.js @@ -686,10 +686,6 @@ window.Spicetify = { playerState.current = Spicetify.Platform.PlayerAPI._state; Spicetify.Player.data = playerState.current; - // for compatibility reasons - // TODO: remove in the future - Spicetify.Player.data["track"] = Spicetify.Player.data.item; - if (playerState.cache?.item.uri !== playerState.current?.item?.uri) { const event = new Event("songchange"); event.data = Spicetify.Player.data;