fix: remove non-standard fields that would cause prisma validation errors
This commit is contained in:
15
package-lock.json
generated
15
package-lock.json
generated
@@ -35722,6 +35722,21 @@
|
|||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=6"
|
"node": ">=6"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"packages/trpc/node_modules/@next/swc-win32-ia32-msvc": {
|
||||||
|
"version": "14.2.6",
|
||||||
|
"resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.2.6.tgz",
|
||||||
|
"integrity": "sha512-hNukAxq7hu4o5/UjPp5jqoBEtrpCbOmnUqZSKNJG8GrUVzfq0ucdhQFVrHcLRMvQcwqqDh1a5AJN9ORnNDpgBQ==",
|
||||||
|
"cpu": [
|
||||||
|
"ia32"
|
||||||
|
],
|
||||||
|
"optional": true,
|
||||||
|
"os": [
|
||||||
|
"win32"
|
||||||
|
],
|
||||||
|
"engines": {
|
||||||
|
"node": ">= 10"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -193,7 +193,15 @@ export const NEXT_AUTH_OPTIONS: AuthOptions = {
|
|||||||
idToken: true,
|
idToken: true,
|
||||||
allowDangerousEmailAccountLinking: true,
|
allowDangerousEmailAccountLinking: true,
|
||||||
|
|
||||||
profile(profile) {
|
profile(profile, tokens) {
|
||||||
|
if (tokens && 'refresh_expires_in' in tokens) {
|
||||||
|
delete tokens.refresh_expires_in;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (tokens && 'not-before-policy' in tokens) {
|
||||||
|
delete tokens['not-before-policy'];
|
||||||
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id: profile.sub,
|
id: profile.sub,
|
||||||
email: profile.email || profile.preferred_username,
|
email: profile.email || profile.preferred_username,
|
||||||
|
|||||||
Reference in New Issue
Block a user