Permissions checks on pad and timeslider in server.js are redudant

This commit is contained in:
Jordan 2011-11-21 15:51:54 -05:00
parent 5e7c5d5dd3
commit 6297e628eb
1 changed files with 6 additions and 12 deletions

View File

@ -210,12 +210,9 @@ async.waterfall([
return;
}
hasPadAccess(req, res, function()
{
res.header("Server", serverName);
var filePath = path.normalize(__dirname + "/../static/pad.html");
res.sendfile(filePath, { maxAge: exports.maxAge });
});
res.header("Server", serverName);
var filePath = path.normalize(__dirname + "/../static/pad.html");
res.sendfile(filePath, { maxAge: exports.maxAge });
});
//serve timeslider.html under /p/$padname/timeslider
@ -228,12 +225,9 @@ async.waterfall([
return;
}
hasPadAccess(req, res, function()
{
res.header("Server", serverName);
var filePath = path.normalize(__dirname + "/../static/timeslider.html");
res.sendfile(filePath, { maxAge: exports.maxAge });
});
res.header("Server", serverName);
var filePath = path.normalize(__dirname + "/../static/timeslider.html");
res.sendfile(filePath, { maxAge: exports.maxAge });
});
//serve timeslider.html under /p/$padname/timeslider