commit f88b6d961e33071e775bd4886ee66df32e63dd69
parent 0426051541a34f0d2dccd4fba0f55b0e23d48511
Author: Dylan Pinsonneault <dylanp2222@gmail.com>
Date: Tue, 28 Feb 2023 20:38:33 -0500
Fix confirmation for removing 2FA and deauthing sessions in admin panel
Diffstat:
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/static/scripts/admin_users.js b/src/static/scripts/admin_users.js
@@ -28,7 +28,8 @@ function remove2fa(event) {
event.preventDefault();
event.stopPropagation();
const id = event.target.parentNode.dataset.vwUserUuid;
- if (!id) {
+ const email = event.target.parentNode.dataset.vwUserEmail;
+ if (!id || !email) {
alert("Required parameters not found!");
return false;
}
@@ -45,7 +46,8 @@ function deauthUser(event) {
event.preventDefault();
event.stopPropagation();
const id = event.target.parentNode.dataset.vwUserUuid;
- if (!id) {
+ const email = event.target.parentNode.dataset.vwUserEmail;
+ if (!id || !email) {
alert("Required parameters not found!");
return false;
}