From bdaf3730c407db7f6a4388d639c2286c85361093 Mon Sep 17 00:00:00 2001 From: iou1name Date: Fri, 20 Nov 2020 21:13:35 -0500 Subject: [PATCH] bugfix non-admin errors --- static/buckler.js | 4 +++- templates/index.html | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/static/buckler.js b/static/buckler.js index 0009e6c..f389266 100644 --- a/static/buckler.js +++ b/static/buckler.js @@ -15,7 +15,9 @@ function load() { } }); }); - document.querySelector('#user_perm_form').addEventListener('submit', submit_user_perms); + if (user_perms) { + document.querySelector('#user_perm_form').addEventListener('submit', submit_user_perms); + } } function submit_user_perms(event) { diff --git a/templates/index.html b/templates/index.html index f6208f5..0196a40 100644 --- a/templates/index.html +++ b/templates/index.html @@ -4,7 +4,7 @@ Buckler