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

This commit is contained in:
ansuz
2018-06-12 15:50:53 +02:00
7 changed files with 17 additions and 5 deletions

View File

@@ -708,9 +708,11 @@ define([
var update = updateLocalVersion(NewConfig.requireConf && NewConfig.requireConf.urlArgs);
if (update) {
postMessage('DISCONNECT');
return;
}
common.onNetworkReconnect.fire(data);
});
common.onNetworkReconnect.fire(data); break;
break;
}
// Messenger
case 'CONTACTS_MESSAGE': {

View File

@@ -96,11 +96,17 @@
// Download a blob from href
var download = function (src, cb) {
var download = function (src, _cb) {
var cb = function (e, res) {
_cb(e, res);
cb = function () {};
};
var xhr = new XMLHttpRequest();
xhr.open('GET', src, true);
xhr.responseType = 'arraybuffer';
xhr.onerror = function () { return void cb("XHR_ERROR"); };
xhr.onload = function () {
// Error?
if (/^4/.test('' + this.status)) { return void cb("XHR_ERROR " + this.status); }

View File

@@ -443,6 +443,7 @@ define([
$err.find('a').click(function () {
funcs.gotoURL();
});
UI.findOKButton().click();
UI.errorLoadingScreen($err, true, true);
});