mirror of
https://iceshrimp.dev/crimekillz/trashposs
synced 2024-11-21 16:33:48 +01:00
[mastodon-client] Preserve state parameter during OAuth
This fixes login with clients that require the state parameter to be preserved during /oauth/authorize.
This commit is contained in:
parent
89bc799765
commit
58137c9482
@ -105,6 +105,7 @@ const props = defineProps<{
|
||||
scope?: string;
|
||||
force_login?: boolean;
|
||||
lang?: string;
|
||||
state?: string;
|
||||
}>();
|
||||
|
||||
const _scopes = props.scope?.split(" ")?.filter(p => p.length > 0) ?? ['read'];
|
||||
@ -165,6 +166,7 @@ async function accept(): Promise<void> {
|
||||
redirectUri,
|
||||
query({
|
||||
code: res.code,
|
||||
state: props.state,
|
||||
}),
|
||||
);
|
||||
}
|
||||
|
@ -354,7 +354,8 @@ export const routes = [
|
||||
redirect_uri: "redirect_uri",
|
||||
scope: "scope",
|
||||
force_login: "force_login",
|
||||
lang: "lang"
|
||||
lang: "lang",
|
||||
state: "state",
|
||||
}
|
||||
},
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user