summaryrefslogtreecommitdiff
path: root/app/Controller/User.php
diff options
context:
space:
mode:
authorFrédéric Guillot <fred@kanboard.net>2014-09-20 12:52:48 +0200
committerFrédéric Guillot <fred@kanboard.net>2014-09-20 12:52:48 +0200
commit00cdc609d113fedf977da1d55136dc4d699fb308 (patch)
tree3e54049861fb2698cd4501bae829c62093d4c982 /app/Controller/User.php
parent5f96af82f26967f4614b89322a82a59cb48bd2a3 (diff)
Extract project permissions to a separate class
Diffstat (limited to 'app/Controller/User.php')
-rw-r--r--app/Controller/User.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Controller/User.php b/app/Controller/User.php
index 72ef521c..504f4aed 100644
--- a/app/Controller/User.php
+++ b/app/Controller/User.php
@@ -189,7 +189,7 @@ class User extends Base
{
$user = $this->getUser();
$this->response->html($this->layout('user_show', array(
- 'projects' => $this->project->getAvailableList($user['id']),
+ 'projects' => $this->projectPermission->getAllowedProjects($user['id']),
'user' => $user,
)));
}
@@ -252,7 +252,7 @@ class User extends Base
}
$this->response->html($this->layout('user_notifications', array(
- 'projects' => $this->project->getAvailableList($user['id']),
+ 'projects' => $this->projectPermission->getAllowedProjects($user['id']),
'notifications' => $this->notification->readSettings($user['id']),
'user' => $user,
)));
@@ -353,7 +353,7 @@ class User extends Base
$this->response->html($this->layout('user_edit', array(
'values' => $values,
'errors' => $errors,
- 'projects' => $this->project->filterListByAccess($this->project->getList(), $user['id']),
+ 'projects' => $this->projectPermission->getAllowedProjects($user['id']),
'user' => $user,
)));
}