follow has been migrated to favorites

This commit is contained in:
booploops 2022-06-09 21:25:38 -07:00
parent 05b6ea112e
commit d7b314e0f5
9 changed files with 257 additions and 222 deletions

View file

@ -194,32 +194,14 @@
icon: "./assets/star.svg",
name: app.getLz('action.favorite'),
action: () => {
app.mk.api.v3.music(`/v1/me/favorites`, {
"art[url]": "f",
"ids[artists]": app.artistPage.data.id,
"l": app.mklang,
"platform": "web"
}, {
fetchOptions: {
method: "POST"
}
})
app.setArtistFavorite(app.artistPage.data.id, true)
}
},
removeFavorite: {
icon: "./assets/star.svg",
name: app.getLz('action.removeFavorite'),
action: () => {
app.mk.api.v3.music(`/v1/me/favorites`, {
"art[url]": "f",
"ids[artists]": app.artistPage.data.id,
"l": app.mklang,
"platform": "web"
}, {
fetchOptions: {
method: "DELETE"
}
})
app.setArtistFavorite(app.artistPage.data.id, false)
}
}
}
@ -241,7 +223,7 @@
}
},
favoriteActions[inFavorites ? "removeFavorite" : "favorite"],
followActions[followAction],
// followActions[followAction],
{
icon: "./assets/feather/share.svg",
name: app.getLz('term.share'),