summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPliable Pixels <pliablepixels@gmail.com>2019-02-10 11:42:56 -0500
committerPliable Pixels <pliablepixels@gmail.com>2019-02-10 11:42:56 -0500
commita2a0c8aab240ff040036849bf710dbffb597e6a8 (patch)
tree1d774ce4c5536094d673f1f2e2b3c0c00d6b2213
parent3fcf9c40fe1a80f80334d78ed856f58a55417df7 (diff)
#781 don't send if state is rejected
-rw-r--r--www/js/EventServer.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/www/js/EventServer.js b/www/js/EventServer.js
index dffb2120..c79aa1dd 100644
--- a/www/js/EventServer.js
+++ b/www/js/EventServer.js
@@ -437,6 +437,11 @@ angular.module('zmApp.controllers')
return;
}
+ if (authState == connState.REJECT && type != 'auth') {
+ NVR.debug ("ERROR: ES rejected authentication, not sending message");
+ return;
+ }
+
if ( authState == connState.PENDING && type != 'auth') {
NVR.debug ("ES Connection not yet authenticated, adding message to queue");
pendingMessages.push ({type:type, obj:obj});