]> git.cworth.org Git - empires-html/blobdiff - empires-client.js
Fix the gear toggle to work the first time it is clicked
[empires-html] / empires-client.js
index 994ed1a4e84680a24cb5815bc9dd72708f79ec6b..a0df9134df1e87de86b9e722a07a141bc6606397 100644 (file)
@@ -30,10 +30,12 @@ function register(form) {
 function toggle_host_tools() {
   const host_tools = document.getElementById("host-tools");
 
-  if (host_tools.style.display === "none")
-    host_tools.style.display = "block";
-  else
+  console.log("Toggling, host_tools.style.display is '" + host_tools.style.display + "'");
+
+  if (host_tools.style.display === "block")
     host_tools.style.display = "none";
+  else
+    host_tools.style.display = "block";
 }
 
 function post_reveal() {