Fix "rendering..." getting stuck on first connection

This commit is contained in:
Pavel Djundik 2018-02-23 21:18:42 +02:00
parent 5bac385a75
commit 7ce1f1cf9e

View File

@ -30,11 +30,11 @@ socket.on("init", function(data) {
render.renderNetworks(data); render.renderNetworks(data);
} }
if (lastMessageId > -1) {
$("#connection-error").removeClass("shown"); $("#connection-error").removeClass("shown");
$(".show-more-button, #input").prop("disabled", false); $(".show-more-button, #input").prop("disabled", false);
$("#submit").show(); $("#submit").show();
} else {
if (lastMessageId < 0) {
if (data.token) { if (data.token) {
storage.set("token", data.token); storage.set("token", data.token);
} }