diff --git a/html/scan.js b/html/scan.js
index a35c304..746bbc5 100644
--- a/html/scan.js
+++ b/html/scan.js
@@ -12,7 +12,11 @@ function init() {
}
function initAat() {
- _('aatsubmit').addEventListener('click', callback('Update AAT Parameters', 'An error occurred changing values', '/aatconfig',
+ let aatsubmit = _('aatsubmit');
+ if (!aatsubmit)
+ return;
+
+ aatsubmit.addEventListener('click', callback('Update AAT Parameters', 'An error occurred changing values', '/aatconfig',
() => { return new URLSearchParams(new FormData(_('aatconfig'))); }
));
_('azim_center').addEventListener('change', aatAzimCenterChanged);
diff --git a/html/txbp_index.html b/html/txbp_index.html
index 47d074a..6dd8f93 100644
--- a/html/txbp_index.html
+++ b/html/txbp_index.html
@@ -13,7 +13,7 @@