From f8f1c2bac013547784da5c4c97870dc959f7de92 Mon Sep 17 00:00:00 2001 From: Paul Ryley <134939+pryley@users.noreply.github.com> Date: Thu, 24 Oct 2024 20:46:27 -0500 Subject: [PATCH] updated docs --- views/pages/documentation/faq/hide-form-after-submission.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/pages/documentation/faq/hide-form-after-submission.php b/views/pages/documentation/faq/hide-form-after-submission.php index cf22dc13..871b100c 100644 --- a/views/pages/documentation/faq/hide-form-after-submission.php +++ b/views/pages/documentation/faq/hide-form-after-submission.php @@ -20,7 +20,7 @@ return $javascript." document.addEventListener('DOMContentLoaded', function () { GLSR.Event.on('site-reviews/form/handle', function (response, form) { - if (true !== response.success || 0 !== response.errors.length) return; + if (true !== response?.success) return; form.classList.add('glsr-hide-form'); form.insertAdjacentHTML('afterend', '<p>' + response.message + '</p>'); });