aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-08-03 11:20:21 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2015-08-03 11:20:21 +1200
commit8e41bea48b0b248bcb198186783778002a92738e (patch)
treec93686359285fcabe316a278c76ef0de78813a33
parenta265f39cef279d84bbeee5be68c17d22896bb685 (diff)
downloadtrackermap-server-8e41bea48b0b248bcb198186783778002a92738e.tar.gz
trackermap-server-8e41bea48b0b248bcb198186783778002a92738e.tar.bz2
trackermap-server-8e41bea48b0b248bcb198186783778002a92738e.zip
Handle HTTP error codes
-rw-r--r--web/app/ErrorManager.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/web/app/ErrorManager.js b/web/app/ErrorManager.js
index e55719571..77e5ae373 100644
--- a/web/app/ErrorManager.js
+++ b/web/app/ErrorManager.js
@@ -27,7 +27,11 @@ Ext.define('Traccar.ErrorManager', {
return false;
}
} else {
- Ext.Msg.alert(strings.errorTitle, response.statusText);
+ if (response.statusText) {
+ Ext.Msg.alert(strings.errorTitle, response.statusText);
+ } else {
+ Ext.Msg.alert(strings.errorTitle, response.status.toString()); // TODO: text message
+ }
return false;
}
},