From 8eae8a4fb5fdb98a9911ed9f7c48773583dc0c21 Mon Sep 17 00:00:00 2001 From: Vincent Briglia Date: Thu, 12 Sep 2013 13:07:00 +0000 Subject: [PATCH] !undefined = true !!undefined = false !!!undefined = true !false = true !!false = false !!!false = true !true = false !!true = true !!!true = false when using isEmailAvailable (positive) in correlation with exists (positive) make sure that the outcome is a positive return (and not an inverted) --- src/user.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/user.js b/src/user.js index 9987662d6e..c2d50ed1bf 100644 --- a/src/user.js +++ b/src/user.js @@ -276,7 +276,7 @@ var utils = require('./../public/src/utils.js'), User.isEmailAvailable = function(email, callback) { RDB.exists('email:' + email + ':uid' , function(err, exists) { - callback(err, !!exists); + callback(err, !!!exists); }); }