mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-13 09:25:45 +01:00
log bcrypt error, closes59
This commit is contained in:
@@ -25,6 +25,15 @@ var user = require('./user.js'),
|
|||||||
|
|
||||||
user.getUserField(uid, 'password', function(user_password) {
|
user.getUserField(uid, 'password', function(user_password) {
|
||||||
bcrypt.compare(password, user_password, function(err, res) {
|
bcrypt.compare(password, user_password, function(err, res) {
|
||||||
|
if(err) {
|
||||||
|
console.log(err);
|
||||||
|
next({
|
||||||
|
status: "error",
|
||||||
|
message: 'bcrypt compare error'
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (res === true) {
|
if (res === true) {
|
||||||
next({
|
next({
|
||||||
status: "ok",
|
status: "ok",
|
||||||
|
|||||||
Reference in New Issue
Block a user