From dcb1b0188a8ecaa93322c07b2fd381d22fbc4aa0 Mon Sep 17 00:00:00 2001 From: Santosh Bhandari Date: Wed, 6 May 2026 10:46:25 +0545 Subject: [PATCH] fix: lowercase email on local registration --- apps/backend/src/services/auth/auth.service.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/backend/src/services/auth/auth.service.ts b/apps/backend/src/services/auth/auth.service.ts index 32b43f3b..187c08ed 100644 --- a/apps/backend/src/services/auth/auth.service.ts +++ b/apps/backend/src/services/auth/auth.service.ts @@ -43,6 +43,9 @@ export class AuthService { if (process.env.DISALLOW_PLUS && body.email.includes('+')) { throw new Error('Email with plus sign is not allowed'); } + if (body instanceof CreateOrgUserDto) { + body.email = body.email.toLowerCase(); + } const user = await this._userService.getUserByEmail(body.email); if (body instanceof CreateOrgUserDto) { if (user) {