Account editing and change password.
This commit is contained in:
@@ -24,11 +24,11 @@ export function isValidId(s) {
|
||||
return validate(s);
|
||||
}
|
||||
|
||||
export function hashPassword(password) {
|
||||
export async function hashPassword(password) {
|
||||
return bcrypt.hash(password, SALT_ROUNDS);
|
||||
}
|
||||
|
||||
export function checkPassword(password, hash) {
|
||||
export async function checkPassword(password, hash) {
|
||||
return bcrypt.compare(password, hash);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user