Revert "fix(mobile): token header for social sign in"

This reverts commit dd0058e4aa.
This commit is contained in:
Stephen Zhou 2025-03-27 17:44:41 +08:00
parent 962c31ffed
commit ed86426728
No known key found for this signature in database
1 changed files with 9 additions and 20 deletions

View File

@ -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]}
>