Fixed indentations
This commit is contained in:
parent
09db8af283
commit
9945f88beb
1 changed files with 92 additions and 88 deletions
|
@ -44,16 +44,20 @@ const MusicKitInterop = {
|
|||
const remainingTimeExport = mk.currentPlaybackTimeRemaining;
|
||||
const attributes = (nowPlayingItem != null ? nowPlayingItem.attributes : {});
|
||||
|
||||
attributes.storefrontId = storefrontId;
|
||||
attributes.status = isPlayingExport ?? false;
|
||||
attributes.name = attributes?.name ?? 'No Title Found';
|
||||
attributes.artwork = attributes?.artwork ?? { url: '' };
|
||||
attributes.artwork.url = (attributes?.artwork?.url ?? '').replace(`{f}`,"png");
|
||||
attributes.playParams = attributes?.playParams ?? { id: 'no-id-found' };
|
||||
attributes.artwork = attributes?.artwork ?? {url: ''};
|
||||
attributes.artwork.url = (attributes?.artwork?.url ?? '').replace(`{f}`, "png");
|
||||
attributes.playParams = attributes?.playParams ?? {id: 'no-id-found'};
|
||||
attributes.playParams.id = attributes?.playParams?.id ?? 'no-id-found';
|
||||
attributes.playParams.songid = nowPlayingItem.songId ?? 'no-id-found'
|
||||
attribtues.url = { cider: "https://cider.sh/p?id=" + attributes.playParams.id, appleMusic: "https://music.apple.com/song/" + nowPlayingItem.songId }
|
||||
if (attributes.playParams.id === 'no-id-found') { attributes.playParams.id = nowPlayingItem?.id ?? 'no-id-found'; }
|
||||
attributes.url = {
|
||||
cider: "https://cider.sh/p?id=" + attributes.playParams.id,
|
||||
appleMusic: "https://music.apple.com/song/" + nowPlayingItem.songId
|
||||
}
|
||||
if (attributes.playParams.id === 'no-id-found') {
|
||||
attributes.playParams.id = nowPlayingItem?.id ?? 'no-id-found';
|
||||
}
|
||||
attributes.albumName = attributes?.albumName ?? '';
|
||||
attributes.artistName = attributes?.artistName ?? '';
|
||||
attributes.genreNames = attributes?.genreNames ?? [];
|
||||
|
@ -71,7 +75,7 @@ const MusicKitInterop = {
|
|||
},
|
||||
|
||||
filterTrack: function (a, playbackCheck, mediaCheck) {
|
||||
if (a.title === "No Title Found" || a.playParams.id === "no-id-found" ) {
|
||||
if (a.title === "No Title Found" || a.playParams.id === "no-id-found") {
|
||||
return;
|
||||
} else if (mediaCheck && a.playParams.id === cache.playParams.id) {
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue