This commit is contained in:
vapormusic 2022-02-18 21:53:31 +07:00
parent 1aec27bc83
commit 99425e65c3
2 changed files with 5 additions and 5 deletions

View file

@ -3254,7 +3254,7 @@ const app = new Vue({
async getRating(item) {
let type = item.type.slice(-1) === "s" ? item.type : item.type + "s"
let id = item.attributes?.playParams?.catalogId ? item.attributes.playParams.catalogId : (item.attributes?.playParams?.id ?? item.id)
if (item.id && item.id.startsWith("i.")) {
if (item.id != null && (item.id.toString()).startsWith("i.")) {
if (!type.startsWith("library-")) {
type = "library-" + type
}
@ -3271,7 +3271,7 @@ const app = new Vue({
love(item) {
let type = item.type.slice(-1) === "s" ? item.type : item.type + "s"
let id = item.attributes?.playParams?.catalogId ? item.attributes.playParams.catalogId : (item.attributes?.playParams?.id ?? item.id)
if (item.id && item.id.startsWith("i.")) {
if (item.id != null && (item.id.toString()).startsWith("i.")) {
if (!type.startsWith("library-")) {
type = "library-" + type
}
@ -3292,7 +3292,7 @@ const app = new Vue({
dislike(item) {
let type = item.type.slice(-1) === "s" ? item.type : item.type + "s"
let id = item.attributes?.playParams?.catalogId ? item.attributes.playParams.catalogId : (item.attributes?.playParams?.id ?? item.id)
if (item.id && item.id.startsWith("i.")) {
if (item.id != null && (item.id.toString()).startsWith("i.")) {
if (!type.startsWith("library-")) {
type = "library-" + type
}
@ -3860,7 +3860,7 @@ function fallbackinitMusicKit() {
},
sourceType: 24,
suppressErrorDialog: true
});
})
setTimeout(() => {
app.init()
}, 1000)