From 85222d711238448a8d421fc0e86ea63656e56bd2 Mon Sep 17 00:00:00 2001 From: maikirakiwi Date: Wed, 6 Jul 2022 18:21:48 -0700 Subject: [PATCH] don't give the lyric api id if local files --- src/renderer/main/vueapp.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/renderer/main/vueapp.js b/src/renderer/main/vueapp.js index 65ab38db..69ff2d0f 100644 --- a/src/renderer/main/vueapp.js +++ b/src/renderer/main/vueapp.js @@ -3039,7 +3039,9 @@ const app = new Vue({ const track = encodeURIComponent((this.mk.nowPlayingItem != null) ? this.mk.nowPlayingItem.title ?? '' : ''); const artist = encodeURIComponent((this.mk.nowPlayingItem != null) ? this.mk.nowPlayingItem.artistName ?? '' : ''); const time = encodeURIComponent((this.mk.nowPlayingItem != null) ? (Math.round((this.mk.nowPlayingItem.attributes["durationInMillis"] ?? -1000) / 1000) ?? -1) : -1); - const id = encodeURIComponent((this.mk.nowPlayingItem != null) ? app.mk.nowPlayingItem._songId ?? (app.mk.nowPlayingItem["songId"] ?? '') : ''); + if (this.mk.nowPlayingItem != null && app.mk.nowPlayingItem.localFilesMetadata != null) {const id = encodeURIComponent('')} + else {const id = encodeURIComponent((this.mk.nowPlayingItem != null) ? (app.mk.nowPlayingItem._songId) ?? (app.mk.nowPlayingItem["songId"] ?? '') : '');} + let lrcfile = ""; let richsync = []; const lang = app.cfg.lyrics.mxm_language // translation language