fix: Incorrect URL Parameter Parsing Causes user_id Retrieval Error (#25261)
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
This commit is contained in:
parent
aff2482436
commit
a932413314
1 changed files with 10 additions and 0 deletions
|
|
@ -43,6 +43,16 @@ async function getProcessedInputsFromUrlParams(): Promise<Record<string, any>> {
|
||||||
|
|
||||||
async function getProcessedSystemVariablesFromUrlParams(): Promise<Record<string, any>> {
|
async function getProcessedSystemVariablesFromUrlParams(): Promise<Record<string, any>> {
|
||||||
const urlParams = new URLSearchParams(window.location.search)
|
const urlParams = new URLSearchParams(window.location.search)
|
||||||
|
const redirectUrl = urlParams.get('redirect_url')
|
||||||
|
if (redirectUrl) {
|
||||||
|
const decodedRedirectUrl = decodeURIComponent(redirectUrl)
|
||||||
|
const queryString = decodedRedirectUrl.split('?')[1]
|
||||||
|
if (queryString) {
|
||||||
|
const redirectParams = new URLSearchParams(queryString)
|
||||||
|
for (const [key, value] of redirectParams.entries())
|
||||||
|
urlParams.set(key, value)
|
||||||
|
}
|
||||||
|
}
|
||||||
const systemVariables: Record<string, any> = {}
|
const systemVariables: Record<string, any> = {}
|
||||||
const entriesArray = Array.from(urlParams.entries())
|
const entriesArray = Array.from(urlParams.entries())
|
||||||
await Promise.all(
|
await Promise.all(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue