Hide drive info box when in read-only mode + update UI

This commit is contained in:
yflory
2019-11-12 17:18:22 +01:00
parent 80f5ebc0cc
commit 2e182788ec
4 changed files with 6 additions and 8 deletions

View File

@@ -77,6 +77,7 @@ define([
manager.folders[fId].userObject.setReadOnly(readOnly, secret.keys.secondaryKey);
}));
});
// Remove from memory folders that have been deleted from the drive remotely
oldIds.forEach(function (fId) {
if (!drive.sharedFolders[fId]) {
delete folders[fId];
@@ -134,7 +135,6 @@ define([
SFCommon.create(waitFor(function (c) { common = c; }));
}).nThen(function (waitFor) {
$('#cp-app-drive-connection-state').text(Messages.disconnected);
$('#cp-app-drive-edition-state').text(Messages.readonly);
var privReady = Util.once(waitFor());
var metadataMgr = common.getMetadataMgr();
if (JSON.stringify(metadataMgr.getPrivateData()) !== '{}') {