From 0c9ae88c3174964020e9b5f231565a425fb1c674 Mon Sep 17 00:00:00 2001 From: "eoghan.conlon" Date: Thu, 27 Jul 2023 19:06:20 +0100 Subject: [PATCH] [pass-reset_script] Fix. Changed lines 2 & 3 to no-longer use a depreciated feature --- src/PassReset/formHandler.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/PassReset/formHandler.js b/src/PassReset/formHandler.js index d59fa04..bae54e5 100644 --- a/src/PassReset/formHandler.js +++ b/src/PassReset/formHandler.js @@ -1,6 +1,6 @@ const formEl = document.getElementById("reset"); -formEl.addEventListener('submit', () => { - event.preventDefault(); +formEl.addEventListener('submit', (listener) => { + listener.preventDefault(); const formData = new FormData(formEl); if(formData.get("newPW") === formData.get("newPWConfirm")){ formData.delete("newPWConfirm");