Browse Source

Merge pull request #1460 from alexcroox/feature/startup-connection-test-delay

Add 5 second delay to processRequest internet connection test
pull/1484/head
Ramiro Saenz 7 years ago committed by GitHub
parent
commit
4aa3e67df4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      index.html

4
index.html

@ -15,7 +15,9 @@
xhr.open('HEAD', file + "?rand=" + randomNum, true); xhr.open('HEAD', file + "?rand=" + randomNum, true);
xhr.send(); xhr.send();
xhr.addEventListener("readystatechange", processRequest, false); xhr.addEventListener("readystatechange", function() {
setTimeout(processRequest, 5000);
}, false);
function processRequest(e) { function processRequest(e) {
if (xhr.readyState == 4) { if (xhr.readyState == 4) {

Loading…
Cancel
Save