diff options
author | Frederic Guillot <fred@kanboard.net> | 2015-12-14 21:12:08 -0500 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2015-12-14 21:12:08 -0500 |
commit | f01e2f4b781651b2fbb9e1dc079c7eaaae14a4d2 (patch) | |
tree | 24313fd32d34f427d9df834ed2a32f459fab659f /app | |
parent | f8bb0b47736e782033b241e4b9982e5c6ab61ef9 (diff) |
Fix wrong constant name that cause a PHP error in project management section
Diffstat (limited to 'app')
-rw-r--r-- | app/Model/ProjectPermission.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Model/ProjectPermission.php b/app/Model/ProjectPermission.php index b311c10b..f74b8587 100644 --- a/app/Model/ProjectPermission.php +++ b/app/Model/ProjectPermission.php @@ -28,10 +28,10 @@ class ProjectPermission extends Base return $this ->db - ->table(self::TABLE) + ->table(ProjectUserRole::TABLE) ->join(User::TABLE, 'id', 'user_id') ->join(Project::TABLE, 'id', 'project_id') - ->eq(self::TABLE.'.role', $role) + ->eq(ProjectUserRole::TABLE.'.role', $role) ->eq(Project::TABLE.'.is_private', 0) ->in(Project::TABLE.'.id', $project_ids) ->columns( @@ -88,7 +88,7 @@ class ProjectPermission extends Base */ public function isMember($project_id, $user_id) { - return in_array($this->projectUserRole->getUSerRole($project_id, $user_id), array(Role::PROJECT_MEMBER, Role::PROJECT_MANAGER)); + return in_array($this->projectUserRole->getUserRole($project_id, $user_id), array(Role::PROJECT_MEMBER, Role::PROJECT_MANAGER)); } /** |