db/SecurityManager: use jshint

This commit is contained in:
booo 2011-12-22 12:01:32 +01:00
parent d63b7cf188
commit 8f208ca444

View file

@ -24,7 +24,7 @@ var async = require("async");
var authorManager = require("./AuthorManager");
var padManager = require("./PadManager");
var sessionManager = require("./SessionManager");
var settings = require("../utils/Settings")
var settings = require("../utils/Settings");
/**
* This function controlls the access to a pad, it checks if the user can access a pad.
@ -81,7 +81,7 @@ exports.checkAccess = function (padID, sessionID, token, password, callback)
// grant access, with author of token
callback(null, statusObject);
}
})
});
//don't continue
return;
@ -95,7 +95,7 @@ exports.checkAccess = function (padID, sessionID, token, password, callback)
var tokenAuthor;
var isPublic;
var isPasswordProtected;
var passwordStatus = password == null ? "notGiven" : "wrong"; // notGiven, correct, wrong
var passwordStatus = password === null ? "notGiven" : "wrong"; // notGiven, correct, wrong
async.series([
//get basic informations from the database
@ -156,7 +156,7 @@ exports.checkAccess = function (padID, sessionID, token, password, callback)
function(callback)
{
//skip this if the pad doesn't exists
if(padExists == false)
if(!padExists)
{
callback();
return;
@ -275,4 +275,4 @@ exports.checkAccess = function (padID, sessionID, token, password, callback)
if(ERR(err, callback)) return;
callback(null, statusObject);
});
}
};