From ac6ad5ea69a7978b18b1e43ef31d60c675f8905f Mon Sep 17 00:00:00 2001 From: Edmund Farrow Date: Fri, 10 Jan 2025 14:38:43 +0000 Subject: [PATCH] api-sample - Allow submit during validation --- api/public/stackshared.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/api/public/stackshared.php b/api/public/stackshared.php index 7413b47267..8cffffec43 100644 --- a/api/public/stackshared.php +++ b/api/public/stackshared.php @@ -179,7 +179,6 @@ function send() { // Validate an input. Called a set amount of time after an input is last updated. function validate(element) { - loading(true); const http = new XMLHttpRequest(); const url = window.location.origin + '/validate'; http.open("POST", url, true); @@ -189,7 +188,6 @@ function validate(element) { http.onreadystatechange = function () { if (http.readyState == 4) { try { - loading(false); const json = JSON.parse(http.responseText); if (json.message) { document.getElementById('errors').innerText = json.message; @@ -211,7 +209,6 @@ function validate(element) { } catch (e) { document.getElementById('errors').innerText = http.responseText; - loading(false); return; } }