From fd79edd786ee0fb36ad61764803f8124ba2e99ad Mon Sep 17 00:00:00 2001 From: yarduon Date: Sat, 14 Sep 2024 21:01:19 +0100 Subject: [PATCH] Avoid spamming edit button when saving --- js/main.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/main.js b/js/main.js index 692c689..941577d 100644 --- a/js/main.js +++ b/js/main.js @@ -977,7 +977,9 @@ document.getElementById("submit-changes").addEventListener("click", (e) => { // Reset winner mode localStorage.setItem("winnerExists", false); // Save team names - editTeam(true); + editTeam( + document.getElementById("edit").children[0].src.includes("save.svg") + ); // Hide burger menu document.getElementById("burger-checkbox").checked = false; } catch (ex) {