diff options
author | Claire <claire.github-309c@sitedethib.com> | 2022-03-08 22:40:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-08 22:40:21 +0100 |
commit | 02133866e6915e37431298b396e1aded1e4c44c5 (patch) | |
tree | 4ec43c5d1269ef7d5a3816a4d000bb7129bf81bd /app/policies | |
parent | f03148f441d8dfc1856451c4faa00b5e26b6e199 (diff) | |
parent | 481f7c8c3850a5d38e92222ab14e5229c49c2812 (diff) |
Merge pull request #1713 from ClearlyClaire/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/policies')
-rw-r--r-- | app/policies/user_policy.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/policies/user_policy.rb b/app/policies/user_policy.rb index 6695a0ddf..92e2c4f4b 100644 --- a/app/policies/user_policy.rb +++ b/app/policies/user_policy.rb @@ -42,7 +42,7 @@ class UserPolicy < ApplicationPolicy end def promote? - admin? && promoteable? + admin? && promotable? end def demote? @@ -51,7 +51,7 @@ class UserPolicy < ApplicationPolicy private - def promoteable? + def promotable? record.approved? && (!record.staff? || !record.admin?) end |