Update server.js

Ignore token if not configured
This commit is contained in:
Jairo Caro-Accino Viciana 2018-08-13 09:59:34 +02:00 committed by GitHub
parent b8443040d1
commit 5012793f23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -209,7 +209,7 @@ app._initializeHTTP = function() {
}
// Auth the req
if (req.params.token !== client.token) {
if (client.token && req.params.token !== client.token) {
res.sendStatus(401);
return;
} else {