mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-10-30 07:26:00 -04:00
fix oauth scopes
This commit is contained in:
16
lib/auth.ts
16
lib/auth.ts
@@ -16,16 +16,12 @@ export const auth = betterAuth({
|
|||||||
github: {
|
github: {
|
||||||
clientId: env.AUTH_GITHUB_CLIENT_ID,
|
clientId: env.AUTH_GITHUB_CLIENT_ID,
|
||||||
clientSecret: env.AUTH_GITHUB_CLIENT_SECRET,
|
clientSecret: env.AUTH_GITHUB_CLIENT_SECRET,
|
||||||
scope: ["read:user"],
|
mapProfileToUser: (profile) => ({
|
||||||
disableDefaultScope: true,
|
name: profile.login,
|
||||||
mapProfileToUser(profile) {
|
email: profile.email,
|
||||||
return {
|
emailVerified: true,
|
||||||
name: profile.login,
|
image: profile.avatar_url,
|
||||||
email: profile.email,
|
}),
|
||||||
emailVerified: true,
|
|
||||||
image: profile.avatar_url,
|
|
||||||
};
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
} satisfies BetterAuthOptions);
|
} satisfies BetterAuthOptions);
|
||||||
|
|||||||
Reference in New Issue
Block a user