mirror of https://github.com/xwiki-labs/cryptpad
Fix ownership issues with forms created from the drive
This commit is contained in:
parent
a7463c1987
commit
74707ea723
|
@ -141,12 +141,13 @@ define([
|
|||
CPNetflux = _CPNetflux;
|
||||
Pinpad = _Pinpad;
|
||||
}));
|
||||
var personalDrive = !Cryptpad.initialTeam || Cryptpad.initialTeam === -1;
|
||||
Cryptpad.getAccessKeys(w(function (_keys) {
|
||||
if (!Array.isArray(_keys)) { return; }
|
||||
accessKeys = _keys;
|
||||
|
||||
_keys.some(function (_k) {
|
||||
if ((!Cryptpad.initialTeam && !_k.id) || Cryptpad.initialTeam === _k.id) {
|
||||
if ((personalDrive && !_k.id) || Cryptpad.initialTeam === _k.id) {
|
||||
myKeys = _k;
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue