Fix cloud auth [object%20Object] (#1226)
This commit is contained in:
parent
7b2bf08b8f
commit
c9c0ab5aca
1 changed files with 3 additions and 3 deletions
|
@ -77,14 +77,14 @@ export async function authorizeCloud() {
|
|||
permissions={0n}
|
||||
clientId={clientId}
|
||||
cancelCompletesFlow={false}
|
||||
callback={async (callbackUrl: string) => {
|
||||
if (!callbackUrl) {
|
||||
callback={async ({ location }: any) => {
|
||||
if (!location) {
|
||||
Settings.cloud.authenticated = false;
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
const res = await fetch(callbackUrl, {
|
||||
const res = await fetch(location, {
|
||||
headers: new Headers({ Accept: "application/json" })
|
||||
});
|
||||
const { secret } = await res.json();
|
||||
|
|
Loading…
Reference in a new issue