summaryrefslogtreecommitdiff
path: root/app/Helper/UserHelper.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2016-09-08 20:44:03 -0400
committerFrederic Guillot <fred@kanboard.net>2016-09-08 20:44:03 -0400
commitfedf4ea2de21fcf95fc5aa942cedc7924865f160 (patch)
treed2dd83bd08de6284c737bbfab47699ed1ef1d984 /app/Helper/UserHelper.php
parentdded773749e869893a00865cf2183a7f0c684038 (diff)
Custom project roles inherit from project members
Diffstat (limited to 'app/Helper/UserHelper.php')
-rw-r--r--app/Helper/UserHelper.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/Helper/UserHelper.php b/app/Helper/UserHelper.php
index e42bafe4..17c66616 100644
--- a/app/Helper/UserHelper.php
+++ b/app/Helper/UserHelper.php
@@ -150,6 +150,11 @@ class UserHelper extends Base
if ($result === null) {
$role = $this->getProjectUserRole($project_id);
+
+ if ($this->role->isCustomProjectRole($role)) {
+ $role = Role::PROJECT_MEMBER;
+ }
+
$result = $this->projectAuthorization->isAllowed($controller, $action, $role);
$this->memoryCache->set($key, $result);
}