fix: normalize email argument before lookup in reset-password

Trims and lowercases the CLI email arg to match the normalization
used elsewhere for user emails, so a differently-cased or
whitespace-padded email no longer falsely reports "User not found".
This commit is contained in:
Shuvo 2026-08-31 22:46:09 +06:00
parent 714bf03244
commit 8db39a8d15

View File

@ -5,7 +5,7 @@ import { and, eq } from "drizzle-orm";
(async () => {
try {
const email = process.argv[2];
const email = process.argv[2]?.trim().toLowerCase();
const randomPassword = await generateRandomPassword();