aboutsummaryrefslogtreecommitdiff
path: root/src/client/util/SharingManager.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2020-10-12 12:53:40 -0400
committerbobzel <zzzman@gmail.com>2020-10-12 12:53:40 -0400
commit04bbff759710d58fa97ce2f0d685ec59b6beb60e (patch)
tree7a2228d8559c873aab69782ccfda42c5c88438f5 /src/client/util/SharingManager.tsx
parent7ede13ca2df4e3889693e33b3f3100b04546d865 (diff)
split getEffectiveAcl code for determining if a field can be modified out into getPropAcl.
Diffstat (limited to 'src/client/util/SharingManager.tsx')
-rw-r--r--src/client/util/SharingManager.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/util/SharingManager.tsx b/src/client/util/SharingManager.tsx
index 0c8f19eae..914253e3c 100644
--- a/src/client/util/SharingManager.tsx
+++ b/src/client/util/SharingManager.tsx
@@ -177,7 +177,7 @@ export class SharingManager extends React.Component<{}> {
users.forEach(({ user, sharingDoc }) => {
if (permission !== SharingPermissions.None) Doc.AddDocToList(sharingDoc, storage, doc); // add the doc to the sharingDoc if it hasn't already been added
- else GetEffectiveAcl(doc, undefined, user.email) === AclPrivate && Doc.RemoveDocFromList(sharingDoc, storage, (doc.aliasOf as Doc || doc)); // remove the doc from the list if it already exists
+ else GetEffectiveAcl(doc, user.email) === AclPrivate && Doc.RemoveDocFromList(sharingDoc, storage, (doc.aliasOf as Doc || doc)); // remove the doc from the list if it already exists
});
}
});
@@ -273,7 +273,7 @@ export class SharingManager extends React.Component<{}> {
distributeAcls(acl, permission as SharingPermissions, doc);
if (permission !== SharingPermissions.None) Doc.AddDocToList(sharingDoc, storage, doc);
- else GetEffectiveAcl(doc, undefined, user.email) === AclPrivate && Doc.RemoveDocFromList(sharingDoc, storage, (doc.aliasOf as Doc || doc));
+ else GetEffectiveAcl(doc, user.email) === AclPrivate && Doc.RemoveDocFromList(sharingDoc, storage, (doc.aliasOf as Doc || doc));
});
}