Prompt for login if comms reconnect fails authentication

This commit is contained in:
Nick O'Leary
2016-04-10 18:49:39 +01:00
parent 0c227be02d
commit 6b0bef61a5
3 changed files with 22 additions and 7 deletions

View File

@@ -89,6 +89,7 @@ function start() {
} else {
var completeConnection = function(userScope,sendAck) {
if (!userScope || !Permissions.hasPermission(userScope,"status.read")) {
ws.send(JSON.stringify({auth:"fail"}));
ws.close();
} else {
pendingAuth = false;