diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 5542c1e53..03b0b534d 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -304,7 +304,6 @@ define([ Messages.fm_forbidden : Messages.error; return void UI.warn(text); } - // XXX add the pad to the team drive var isTemplate = priv.isTemplate || data.isTemplate; toAddTeams.forEach(function (obj) { sframeChan.query('Q_STORE_IN_TEAM', { @@ -505,7 +504,6 @@ define([ if (data.href || data.roHref) { parsed = Hash.parsePadUrl(data.href || data.roHref); } - // XXX Teams owner: transfer ownership if (owned && data.roHref && parsed.type !== 'drive' && parsed.hashData.type === 'pad') { var manageOwners = h('button.no-margin', Messages.owner_openModalButton); $(manageOwners).click(function () { diff --git a/www/common/cryptpad-common.js b/www/common/cryptpad-common.js index 0516bf057..067112264 100644 --- a/www/common/cryptpad-common.js +++ b/www/common/cryptpad-common.js @@ -838,7 +838,6 @@ define([ postMessage('GET_PAD_METADATA', data, cb); }; - // XXX Teams: change the password of a pad owned by the team common.changePadPassword = function (Crypt, Crypto, data, cb) { var href = data.href; var newPassword = data.password; diff --git a/www/teams/main.js b/www/teams/main.js index 5c66c573e..d37de141c 100644 --- a/www/teams/main.js +++ b/www/teams/main.js @@ -36,31 +36,7 @@ define([ }; window.addEventListener('message', onMsg); }).nThen(function (/*waitFor*/) { - var teamId; // XXX - var afterSecrets = function (Cryptpad, Utils, secret, cb) { - return void cb(); - /* - var hash = window.location.hash.slice(1); - if (hash && Utils.LocalStore.isLoggedIn()) { - return; // XXX How to add a shared folder? - // Add a shared folder! - Cryptpad.addSharedFolder(teamId, secret, function (id) { - window.CryptPad_newSharedFolder = id; - cb(); - }); - return; - } else if (hash) { - var id = Utils.Util.createRandomInteger(); - window.CryptPad_newSharedFolder = id; - var data = { - href: Utils.Hash.getRelativeHref(window.location.href), - password: secret.password - }; - return void Cryptpad.loadSharedFolder(id, data, cb); - } - cb(); - */ - }; + var teamId; var addRpc = function (sframeChan, Cryptpad) { sframeChan.on('Q_SET_TEAM', function (data, cb) { teamId = data; @@ -72,11 +48,6 @@ define([ data.teamId = teamId; Cryptpad.userObjectCommand(data, cb); }); - // XXX no drive restore in teams? you could restore old keys... - /*sframeChan.on('Q_DRIVE_RESTORE', function (data, cb) { - data.teamId = teamId; - Cryptpad.restoreDrive(data, cb); - });*/ sframeChan.on('Q_DRIVE_GETOBJECT', function (data, cb) { if (!teamId) { return void cb({error: 'EINVAL'}); } if (data && data.sharedFolder) { @@ -109,7 +80,6 @@ define([ }); }; SFCommonO.start({ - afterSecrets: afterSecrets, noHash: true, noRealtime: true, //driveEvents: true,