diff --git a/www/assets/js/callbacks.js b/www/assets/js/callbacks.js index c17b9d54..0ce9effd 100644 --- a/www/assets/js/callbacks.js +++ b/www/assets/js/callbacks.js @@ -136,8 +136,11 @@ function initCallbacks() { }); socket.on("login", function(data) { - if(!data.success && data.error != "Invalid session") - alert(data.error); + if(!data.success) { + if(data.error != "Invalid session") { + alert(data.error); + } + } else { $("#welcome")[0].innerHTML = "Welcome, " + uname; $("#loginform").css("display", "none");