Merge branch 'staging' of github.com:xwiki-labs/cryptpad into staging

This commit is contained in:
yflory
2017-02-13 11:10:40 +01:00
5 changed files with 20 additions and 16 deletions

View File

@@ -44,6 +44,18 @@ define([
return;
};
var whenRealtimeSyncs = common.whenRealtimeSyncs = function (realtime, cb) {
realtime.sync();
var interval = 300;
var check = function () {
if (realtime.getAuthDoc() !== realtime.getUserDoc()) {
return window.setTimeout(check, interval);
}
cb();
};
window.setTimeout(check, interval);
};
var getWebsocketURL = common.getWebsocketURL = function () {
if (!Config.websocketPath) { return Config.websocketURL; }
var path = Config.websocketPath;