diff --git a/www/common/outer/userObject.js b/www/common/outer/userObject.js index 75a33090d..950f7c679 100644 --- a/www/common/outer/userObject.js +++ b/www/common/outer/userObject.js @@ -13,12 +13,8 @@ define([ }; module.init = function (config, exp, files) { - var removeOwnedChannel = config.removeOwnedChannel || function () { - console.error("removeOwnedChannel was not provided"); - }; var loggedIn = config.loggedIn; var sharedFolder = config.sharedFolder; - var edPublic = config.edPublic; var readOnly = config.readOnly; @@ -145,30 +141,6 @@ define([ if (filesList.indexOf(id) === -1) { var fd = exp.isSharedFolder(id) ? files[SHARED_FOLDERS][id] : exp.getFileData(id); var channelId = fd.channel; - // If trying to remove an owned pad, remove it from server also - /* - if (!sharedFolder && fd.owners && fd.owners.indexOf(edPublic) !== -1 - && channelId) { - if (channelId) { ownedRemoved.push(channelId); } - Feedback.send('REMOVE_OWNED_CHANNEL'); - removeOwnedChannel(channelId, function (obj) { - if (obj && obj.error) { - // If the error is that the file is already removed, nothing to - // report, it's a normal behavior (pad expired probably) - if (obj.error.code === 'ENOENT') { return; } - - // RPC may not be responding - // Send a report that can be handled manually - console.error(obj.error); - Feedback.send('ERROR_DELETING_OWNED_PAD=' + channelId + '|' + obj.error, true); - } - }); - // Also remove the realtime channel for onlyoffice - if (fd.rtChannel) { - removeOwnedChannel(fd.rtChannel, function () {}); - } - } - */ if (fd.lastVersion) { toClean.push(Hash.hrefToHexChannelId(fd.lastVersion)); } if (fd.rtChannel) { toClean.push(fd.rtChannel); } if (channelId) { toClean.push(channelId); } diff --git a/www/common/proxy-manager.js b/www/common/proxy-manager.js index 35cb340ee..49876a8b1 100644 --- a/www/common/proxy-manager.js +++ b/www/common/proxy-manager.js @@ -707,7 +707,6 @@ define([ } var toUnpin = []; - var ownedRemoved; nThen(function (waitFor)  { // Delete paths from the main drive and get the list of pads to unpin // We also get the list of owned pads that were removed