From f3d3dfa075ced44622b5a84387d95281def3b5a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julius=20H=C3=A4rtl?= Date: Mon, 20 Feb 2023 09:17:15 +0100 Subject: [PATCH] fix: Avoid throwing errors on public auth page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Julius Härtl --- core/js/publicshareauth.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/js/publicshareauth.js b/core/js/publicshareauth.js index 374d7e92e16..3d694c7bfd6 100644 --- a/core/js/publicshareauth.js +++ b/core/js/publicshareauth.js @@ -47,6 +47,8 @@ document.addEventListener('DOMContentLoaded', function() { // Adds functionality to the request password button var passwordRequestButton = document.getElementById('request-password-button-not-talk'); - passwordRequestButton.addEventListener('click', showEmailAddressPromptForm); + if (passwordRequestButton) { + passwordRequestButton.addEventListener('click', showEmailAddressPromptForm); + } });