Fixes
This commit is contained in:
parent
08a9eae2d3
commit
df62ee8d58
9 changed files with 32 additions and 4 deletions
|
|
@ -27,7 +27,7 @@ function handleLogin(req, res) {
|
|||
dest = dest.match(/login|logout/) ? null : dest;
|
||||
|
||||
if (typeof name !== "string" || typeof password !== "string") {
|
||||
res.send(400);
|
||||
res.sendStatus(400);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -35,7 +35,7 @@ function handleLogin(req, res) {
|
|||
if (host.indexOf(Config.get("http.root-domain")) === -1 &&
|
||||
Config.get("http.alt-domains").indexOf(host) === -1) {
|
||||
Logger.syslog.log("WARNING: Attempted login from non-approved domain " + host);
|
||||
return res.send(403);
|
||||
return res.sendStatus(403);
|
||||
}
|
||||
|
||||
var expiration;
|
||||
|
|
@ -166,7 +166,7 @@ function handleRegister(req, res) {
|
|||
var ip = webserver.ipForRequest(req);
|
||||
|
||||
if (typeof name !== "string" || typeof password !== "string") {
|
||||
res.send(400);
|
||||
res.sendStatus(400);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue