Permalink
Browse files

Converting whatever comes to a string before comparing the login.

  • Loading branch information...
1 parent 02ad113 commit b04f307c89bd8c7623606380a224ee9280488a15 @DracoBlue committed Jul 3, 2010
Showing with 4 additions and 1 deletion.
  1. +4 −1 json-file-user-manager/lib/JsonFileUserManager.js
@@ -32,6 +32,9 @@ JsonFileUserManager.prototype.logging_prefix = 'JsonFileUserManager';
JsonFileUserManager.prototype.checkLogin = function(username, password) {
var self = this;
+
+ username = (username || "").toString();
+ password = (password || "").toString();
this.trace('checkLogin', arguments);
return function(cb) {
@@ -48,4 +51,4 @@ JsonFileUserManager.prototype.checkLogin = function(username, password) {
cb(false);
};
-};
+};

0 comments on commit b04f307

Please sign in to comment.