Fix deprecated shared folder in read-only team

This commit is contained in:
yflory
2019-10-25 17:40:31 +02:00
parent 37a72d2f87
commit 49766d006f
4 changed files with 22 additions and 6 deletions

View File

@@ -54,9 +54,9 @@ define([
var deprecateProxy = function (Env, id, channel) {
if (Env.user.userObject.readOnly) {
// In a read-only team, we can't deprecate a shared folder
if (Env.folders[id]) {
Env.folders[id].proxy = { deprecated: true };
}
// Use a empty object with a deprecated flag...
var lm = { proxy: { deprecated: true } };
addProxy(Env, id, lm, function () {});
return void Env.Store.refreshDriveUI();
}
if (channel) { Env.unpinPads([channel], function () {}); }