From 0c9a608ef9f37124f7a5a1a4e2b8da0976e75ec0 Mon Sep 17 00:00:00 2001 From: Goel Biju <16869075+GoelBiju@users.noreply.github.com> Date: Fri, 27 Mar 2026 02:51:00 +0000 Subject: [PATCH] Correct Spotify Login regex Fixes the regex string which would previously not match on the spotify login URL. --- .../maxrave/simpmusic/ui/screen/login/SpotifyLoginScreen.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composeApp/src/commonMain/kotlin/com/maxrave/simpmusic/ui/screen/login/SpotifyLoginScreen.kt b/composeApp/src/commonMain/kotlin/com/maxrave/simpmusic/ui/screen/login/SpotifyLoginScreen.kt index d89319d7..6b9152ac 100644 --- a/composeApp/src/commonMain/kotlin/com/maxrave/simpmusic/ui/screen/login/SpotifyLoginScreen.kt +++ b/composeApp/src/commonMain/kotlin/com/maxrave/simpmusic/ui/screen/login/SpotifyLoginScreen.kt @@ -172,7 +172,7 @@ fun SpotifyLoginScreen( } viewModel.setFullSpotifyCookies(cookies) } - if (Regex("^https://accounts\\.spotify\\.com/[a-z]{2}(-[a-zA-Z]{2})?/status$").matches(url)) { + if (Regex("^https://accounts\\.spotify\\.com/([a-z]{2}(-[a-zA-Z]{2})?/)?status(\\?.*)?$").matches(url)) { cookie .takeIf { it.isNotEmpty() @@ -227,4 +227,4 @@ fun SpotifyLoginScreen( ), ) } -} \ No newline at end of file +}