diff options
author | Frédéric Guillot <fred@kanboard.net> | 2018-05-02 14:17:29 -0700 |
---|---|---|
committer | Frédéric Guillot <fred@kanboard.net> | 2018-05-02 14:17:29 -0700 |
commit | fa90a294906454a15d17cc1c374eeda73640c350 (patch) | |
tree | 3580023c99cfe95ea31633c051edba49bd07cd3d /app/Template/project_permission | |
parent | b9a457fc031bc048da74961d91999ac9bb2c6946 (diff) |
Avoid people to remove themselves from project permissions
Diffstat (limited to 'app/Template/project_permission')
-rw-r--r-- | app/Template/project_permission/users.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/Template/project_permission/users.php b/app/Template/project_permission/users.php index 1180fe1c..54c85574 100644 --- a/app/Template/project_permission/users.php +++ b/app/Template/project_permission/users.php @@ -21,7 +21,9 @@ )) ?> </td> <td> - <?= $this->url->icon('trash-o', t('Remove'), 'ProjectPermissionController', 'removeUser', array('project_id' => $project['id'], 'user_id' => $user['id']), true) ?> + <?php if (! $this->user->isCurrentUser($user['id'])): ?> + <?= $this->url->icon('trash-o', t('Remove'), 'ProjectPermissionController', 'removeUser', array('project_id' => $project['id'], 'user_id' => $user['id']), true) ?> + <?php endif ?> </td> </tr> <?php endforeach ?> |