apps/api: fix /reset-password

This commit is contained in:
vchikalkin 2024-01-17 17:54:25 +03:00
parent f8c78bfa40
commit ab4612ff12

View File

@ -65,6 +65,7 @@ export class AccountService {
if (!account) throw new UnauthorizedException('Account not found');
const new_password = generatePassword();
await this.accountModel.findOneAndUpdate({ username }, { password: new_password }).exec();
return { password: new_password, username };
}