diff --git a/app/templates/index.html b/app/templates/index.html
index 2e56bbb..b9363d0 100644
--- a/app/templates/index.html
+++ b/app/templates/index.html
@@ -221,7 +221,7 @@ input:checked + .slider:before {
var badge = document.getElementById(badgeid);
if (message.action == "on") {
- checkbox.setAttribute('checked', 'checked');
+ checkbox.setAttribute('checked');
badge.textContent = "On";
badge.classList.replace("badge-danger","badge-success");
} else {