fix: spotify connection

This commit is contained in:
trisua 2025-06-22 14:11:15 -04:00
parent 2f83497f98
commit efd4ac8104
2 changed files with 5 additions and 1 deletions

View file

@ -12,6 +12,7 @@
(text "{% if connection_type == \"Spotify\" and user and user.connections.Spotify and config.connections.spotify_client_id %}")
(script
("defer" "true")
(text "setTimeout(async () => {
const code = new URLSearchParams(window.location.search).get(\"code\");
const client_id = \"{{ config.connections.spotify_client_id }}\";
@ -46,10 +47,11 @@
setTimeout(() => {
window.location.href = \"/settings#/connections\";
}, 500);
}, 150);"))
}, 1000);"))
(text "{% elif connection_type == \"LastFm\" and user and user.connections.LastFm and config.connections.last_fm_key %}")
(script
("defer" "true")
(text "setTimeout(async () => {
const token = new URLSearchParams(window.location.search).get(\"token\");
const api_key = \"{{ config.connections.last_fm_key }}\";