aboutsummaryrefslogtreecommitdiff
path: root/js/util.js
diff options
context:
space:
mode:
authorEinar Egilsson <einar@einaregilsson.com>2019-12-13 10:15:32 +0000
committerEinar Egilsson <einar@einaregilsson.com>2019-12-13 10:15:32 +0000
commitb473306d442b92123cf505dd634faeb141714614 (patch)
treeb0b35eba4f70e3ba06fce6d8d785237e738449f2 /js/util.js
parent8ca4e7c6f7b9465b8dafdf8798bf609f9764ea0e (diff)
Replace .innerHTML with .textContent and bump version
Diffstat (limited to 'js/util.js')
-rw-r--r--js/util.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/js/util.js b/js/util.js
index 43eaa69..a751497 100644
--- a/js/util.js
+++ b/js/util.js
@@ -32,7 +32,7 @@ function dataBind(el, dataObject) {
}
} else {
- tag.innerHTML = dataObject[prop];
+ tag.textContent = dataObject[prop];
}
}
for (let tag of el.querySelectorAll('[data-show]')) {
@@ -102,7 +102,7 @@ function showMessage(message, success) {
//Remove the message in 20 seconds if it hasn't been changed...
setTimeout(function() {
- if (el('#message').innerHTML === message) {
+ if (el('#message').textContent === message) {
messageBox.className = ''; //Removing .visible removes the box...
}
}, timer * 1000);