2026-05-26 15:48:01 +05:30
|
|
|
import bcrypt from 'bcryptjs';
|
2026-03-12 14:15:44 +05:30
|
|
|
|
|
|
|
|
export async function hashPassword(password) {
|
|
|
|
|
return bcrypt.hash(password, 10);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function comparePassword(password, hash) {
|
|
|
|
|
return bcrypt.compare(password, hash);
|
|
|
|
|
}
|