Fixed token issue

This commit is contained in:
Alex Holliday committed 2024-07-16 14:40:37 -07:00
1 parent 9be266c52f
commit f169809692
2 files changed
+4 -4

No files matched your search

+1 -2
View File
@@ -220,8 +220,7 @@ const resetPassword = async (req, res) => {
})
.select("-password")
.select("-profileImage");
const token = issueToken(userWithoutPassword);
return { user: userWithoutPassword, token: token };
return userWithoutPassword;
} else {
throw new Error(errorMessages.DB_USER_NOT_FOUND);
}