From 6ef58a6f661e1818f12e682d1eb3faeac94d8224 Mon Sep 17 00:00:00 2001 From: Trenton Zimmer <66042448+trmazi@users.noreply.github.com> Date: Tue, 21 Apr 2026 14:19:01 -0400 Subject: [PATCH] add state request query params to the callback --- src/views/Auth/AuthorizeView.vue | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/views/Auth/AuthorizeView.vue b/src/views/Auth/AuthorizeView.vue index d0231ff..95fa223 100644 --- a/src/views/Auth/AuthorizeView.vue +++ b/src/views/Auth/AuthorizeView.vue @@ -11,6 +11,7 @@ import { InternalApps } from "@/constants/developer/apps.js"; const CDN_URL = import.meta.env.VITE_CDN_URL; const route = useRoute(); const clientId = route.query.client_id; +const stateData = route.query.state; const clientData = ref(null); onMounted(async () => { @@ -42,8 +43,12 @@ const submit = async () => { console.error("Authorization failed"); } - window.location.href = - clientData.value.callbackUrl + "?code=" + response.code; + var path = `${clientData.value.callbackUrl}?code=${response.code}`; + if (stateData) { + path = path.concat([`&state=${stateData}`]); + } + + window.location.href = path; };