Getting email verification error
8436 }
8437 const whereClause = convertWhereClause(model, where);
8438 const transformed = transformInput(update, model, "update");
→ 8439 const result = await db[getModelName(model)].update({
where: {
email: "[email protected]",
? id?: String,
? AND?: UserWhereInput | UserWhereInput[],
? OR?: UserWhereInput[],
? NOT?: UserWhereInput | UserWhereInput[],
? name?: StringFilter | String,
? emailVerified?: BoolFilter | Boolean,
? image?: StringNullableFilter | String | Null,
? createdAt?: DateTimeFilter | DateTime,
? updatedAt?: DateTimeFilter | DateTime,
? role?: StringNullableFilter | String | Null,
? banned?: BoolNullableFilter | Boolean | Null,
? banReason?: StringNullableFilter | String | Null,
? banExpires?: DateTimeNullableFilter | DateTime | Null,
? pincode?: StringFilter | String,
? gender?: StringFilter | String,
? agreedToTerms?: BoolFilter | Boolean,
? sessions?: SessionListRelationFilter,
? accounts?: AccountListRelationFilter
},
data: {
emailVerified: true
}
})
Argument
where
of type UserWhereUniqueInput needs at least one of id
arguments. Available options are marked with ?.] {
clientVersion: '6.4.1'
}
GET /api/auth/verify-email?token=eyJhbGciOiJIUzI1NiJ9.eyJlbWFpbCI6InZhbnNoY2h=z8FUvG-ZBQLTY9rJP_WzSiIE-QfD0GNSrRAw&callbackURL=/1 Reply
Solution
Fixed: Better autht prisma schema was missing unique on email