(js) Prohibit subscribing a user with no rights

This commit is contained in:
Francis Lachapelle committed 2018-08-28 12:34:27 -04:00
1 parent dfcc14356a
commit 0e2c93864b
4 files changed
+28 -1

No files matched your search

@@ -26,6 +26,7 @@
vm.addUser = addUser;
vm.selectAllRights = selectAllRights;
vm.selectUser = selectUser;
vm.hasNoRight = hasNoRight;
vm.showRights = showRights;
vm.confirmation = { showing: false,
message: ''};
@@ -104,6 +105,10 @@
}
}
function hasNoRight(user) {
return folder.$acl.$hasNoRight(user);
}
function showRights(user) {
return vm.selectedUid == user.uid && !user.inactive;
}