Fix drive stuck offline because of a restricted shared folder

pull/1/head
yflory 4 years ago committed by ansuz
parent ebb6f40652
commit 8f47b183b3

@ -2,7 +2,7 @@ define([
'/common/common-util.js', '/common/common-util.js',
'/bower_components/localforage/dist/localforage.min.js', '/bower_components/localforage/dist/localforage.min.js',
], function (Util, localForage) { ], function (Util, localForage) {
var S = {}; var S = window.CryptPad_Cache = {};
var onReady = Util.mkEvent(true); var onReady = Util.mkEvent(true);
// Check if indexedDB is allowed // Check if indexedDB is allowed

@ -249,6 +249,7 @@ define([
if (obj.store.handleSharedFolder) { if (obj.store.handleSharedFolder) {
obj.store.handleSharedFolder(obj.id, null); obj.store.handleSharedFolder(obj.id, null);
} }
obj.cb();
}); });
} catch (e) {} } catch (e) {}
delete allSharedFolders[secret.channel]; delete allSharedFolders[secret.channel];
@ -260,6 +261,7 @@ define([
if (info.error === "ERESTRICTED" ) { if (info.error === "ERESTRICTED" ) {
sf.teams.forEach(function (obj) { sf.teams.forEach(function (obj) {
obj.store.manager.restrictedProxy(obj.id, secret.channel); obj.store.manager.restrictedProxy(obj.id, secret.channel);
obj.cb();
}); });
delete allSharedFolders[secret.channel]; delete allSharedFolders[secret.channel];
return void cb(); return void cb();

Loading…
Cancel
Save