try to fix upload error, make initial draw faster
[lantea.git] / js / ui.js
index 352f7e78b6448a0fd4f5ef4ed0c677282ec90d6f..5d2c7b005a975669bdd11a0b6e2aecd67b9eb3a3 100644 (file)
--- a/js/ui.js
+++ b/js/ui.js
@@ -337,7 +337,7 @@ function uploadTrack() {
   // then ask for credentials, and then send again.
   var hXHR = new XMLHttpRequest();
   hXHR.onreadystatechange = function() {
   // then ask for credentials, and then send again.
   var hXHR = new XMLHttpRequest();
   hXHR.onreadystatechange = function() {
-    if (hXHR.readyState == 4 && (XHR.status == 200 || hXHR.status == 400)) {
+    if (hXHR.readyState == 4 && (hXHR.status == 200 || hXHR.status == 400)) {
       // 400 is Bad Request, but that's expected as this was empty.
       // So far so good, init actual upload.
       var XHR = new XMLHttpRequest();
       // 400 is Bad Request, but that's expected as this was empty.
       // So far so good, init actual upload.
       var XHR = new XMLHttpRequest();