From 494bd8aab3834cc8312df78aa8e60868ef884ba0 Mon Sep 17 00:00:00 2001 From: spiral Date: Tue, 20 Sep 2022 15:08:42 +0000 Subject: [PATCH] fix(dashboard): add missing return after error handling --- dashboard/src/pages/DiscordLogin.svelte | 1 + 1 file changed, 1 insertion(+) diff --git a/dashboard/src/pages/DiscordLogin.svelte b/dashboard/src/pages/DiscordLogin.svelte index 98593a34..d103453a 100644 --- a/dashboard/src/pages/DiscordLogin.svelte +++ b/dashboard/src/pages/DiscordLogin.svelte @@ -17,6 +17,7 @@ res = await api().private.discord.callback.post({ data: { code: params.get("code"), redirect_domain: window.location.origin } }); } catch(e) { text = "Error: " + e.data.error; + return; } localStorage.setItem("pk-token", res.token); localStorage.setItem("pk-user", JSON.stringify(res.system));