diff --git a/homework/state.js b/homework/state.js index 1b7aef9..7dd2145 100644 --- a/homework/state.js +++ b/homework/state.js @@ -2,6 +2,7 @@ function toggleState(entry_id) { // Toggle UI state const element = document.getElementById("dot-" + entry_id); if (element.innerHTML.toString().includes("fa-circle")) { + element.innerHTML = element.innerHTML.replace("fa-circle-xmark", "fa-check-circle"); element.innerHTML = element.innerHTML.replace("fa-circle", "fa-check-circle"); var checked = 1; } else if (element.innerHTML.toString().includes("fa-check-circle")) { @@ -18,4 +19,4 @@ function toggleState(entry_id) { }, success: (data) => { if (data != "success") console.log(data); } }); -} \ No newline at end of file +}