mirror of
https://github.com/JetSprow/J-Board-Lite.git
synced 2026-05-01 01:14:10 +05:30
fix: respect email verification setting
This commit is contained in:
@@ -26,7 +26,7 @@ export async function createUser(formData: FormData) {
|
||||
const data = createUserSchema.parse(Object.fromEntries(formData));
|
||||
const hashed = await bcrypt.hash(data.password, 12);
|
||||
const user = await prisma.user.create({
|
||||
data: { email: data.email, password: hashed, name: data.name || null, role: data.role },
|
||||
data: { email: data.email, emailVerifiedAt: new Date(), password: hashed, name: data.name || null, role: data.role },
|
||||
});
|
||||
await recordAuditLog({
|
||||
actor: actorFromSession(session),
|
||||
|
||||
Reference in New Issue
Block a user