fix reset password error when user does not exist

This commit is contained in:
Pouria Ezzati 2025-01-22 09:13:09 +03:30
parent 91ea35f7ae
commit 4a34cfe993

View File

@ -72,7 +72,7 @@ async function update(match, update, methods) {
});
const user = await query.select("id").first();
if (!user) return null;
if (!user) return {};
const updateQuery = trx("users").where("id", user.id);
if (methods?.increments) {