Setup filtering for discordrpc

This commit is contained in:
Core 2022-02-02 16:17:19 +00:00
parent 8da0ebed97
commit b4e0869215
No known key found for this signature in database
GPG key ID: FE9BF1B547F8F3C6
2 changed files with 44 additions and 15 deletions

View file

@ -51,8 +51,8 @@ const MusicKitInterop = {
attributes.playParams = attributes?.playParams ?? {id: 'no-id-found'};
attributes.playParams.id = attributes?.playParams?.id ?? 'no-id-found';
attributes.url = {
cider: "cider://play/s/" + nowPlayingItem?._songId ?? 'no-id-found',
appleMusic: "https://music.apple.com/"+ mk.storefrontId +"/song/" + nowPlayingItem?._songId ?? 'no-id-found'
cider: `cider://play/s/${nowPlayingItem?._songId ?? 'no-id-found'}`,
appleMusic: attributes.websiteUrl ? attributes.websiteUrl : `https://music.apple.com/${mk.storefrontId}/song/${nowPlayingItem?._songId ?? 'no-id-found'}`
}
if (attributes.playParams.id === 'no-id-found') {
attributes.playParams.id = nowPlayingItem?.id ?? 'no-id-found';