Skip to content

TagSpaces is an offline, open source, document manager with tagging support

merging changes

uggrockab9073b9b6da
diff --cc data/web/web.api.js
index 1de423cb1,6b7f609bb..cbb27f101
--- a/data/web/web.api.js
+++ b/data/web/web.api.js
@@@ -43,11 -44,33 +43,24 @@@ define(function(require, exports, modul
});
}
- var run = function() {
+ Offline.on('confirmed-up', function() {
+ $('#dialogLostConnection').modal('hide');
+ });
+ Offline.on('confirmed-down', showLostConnectionDialog);
+
++/* var run = function() {
+ if (Offline.state === 'up') {
+ $('#dialogLostConnection').modal('hide');
+ Offline.check();
+ //});
+ } else if (Offline.state === 'down') {
+ Offline.check();
+ showLostConnectionDialog();
+ console.log("Server is down");
+ }
+ };
- setInterval(run, 5000);
-
- //Offline.on('up', function() {
- // Offline.check();
- // $('#dialogLostConnection').modal('hide');
- //});
- //Offline.on('down', function() {
- // var isOffline = function() {
- // Offline.check();
- // showLostConnectionDialog();
- // console.log("Server is down");
- // };
- // setInterval(isOffline, 5000);
- //});
-
++ setInterval(run, 5000);*/
+
var davClient;
//exact copy of getAjax with timeout added
nl.sara.webdav.Client.prototype.getAjax = function(method, url, callback, headers) {