Revert "fix(mobile): token header for social sign in"
This reverts commit dd0058e4aa.
This commit is contained in:
parent
962c31ffed
commit
ed86426728
|
|
@ -6,7 +6,6 @@ import { AppleCuteFiIcon } from "@/src/icons/apple_cute_fi"
|
|||
import { GithubCuteFiIcon } from "@/src/icons/github_cute_fi"
|
||||
import { GoogleCuteFiIcon } from "@/src/icons/google_cute_fi"
|
||||
import { signIn, useAuthProviders } from "@/src/lib/auth"
|
||||
import { getTokenHeaders } from "@/src/lib/token"
|
||||
|
||||
const provider: Record<
|
||||
string,
|
||||
|
|
@ -65,17 +64,12 @@ export function SocialLogin() {
|
|||
})
|
||||
|
||||
if (credential.identityToken) {
|
||||
await signIn.social(
|
||||
{
|
||||
provider: "apple",
|
||||
idToken: {
|
||||
token: credential.identityToken,
|
||||
},
|
||||
await signIn.social({
|
||||
provider: "apple",
|
||||
idToken: {
|
||||
token: credential.identityToken,
|
||||
},
|
||||
{
|
||||
headers: await getTokenHeaders(),
|
||||
},
|
||||
)
|
||||
})
|
||||
} else {
|
||||
throw new Error("No identityToken.")
|
||||
}
|
||||
|
|
@ -86,15 +80,10 @@ export function SocialLogin() {
|
|||
return
|
||||
}
|
||||
|
||||
signIn.social(
|
||||
{
|
||||
provider: providerInfo.id as any,
|
||||
callbackURL: "/",
|
||||
},
|
||||
{
|
||||
headers: await getTokenHeaders(),
|
||||
},
|
||||
)
|
||||
signIn.social({
|
||||
provider: providerInfo.id as any,
|
||||
callbackURL: "/",
|
||||
})
|
||||
}}
|
||||
disabled={!data?.[providerInfo.id]}
|
||||
>
|
||||
|
|
|
|||
Loading…
Reference in New Issue