fix: missinge xports

This commit is contained in:
karishmas6
2024-09-23 23:53:35 +05:30
parent e51ce53c68
commit 8b8b233510

View File

@@ -1,6 +1,6 @@
import bcrypt from "bcrypt";
const hashPassword = (password) => {
export const hashPassword = (password) => {
return new Promise((resolve, reject) => {
bcrypt.genSalt(12, (err, salt) => {
if (err) {
@@ -17,8 +17,6 @@ const hashPassword = (password) => {
}
// password from frontend and hash from database
const comparePassword = (password, hash) => {
export const comparePassword = (password, hash) => {
return bcrypt.compare(password, hash)
}
module.exports = { hashPassword, comparePassword }
}