diff options
Diffstat (limited to 'app/policies/user_policy.rb')
-rw-r--r-- | app/policies/user_policy.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/app/policies/user_policy.rb b/app/policies/user_policy.rb index fd5708f742f..43f472b4c1d 100644 --- a/app/policies/user_policy.rb +++ b/app/policies/user_policy.rb @@ -13,11 +13,6 @@ class UserPolicy < BasePolicy desc "The user is blocked" condition(:blocked_user, scope: :subject, score: 0) { @subject.blocked? } - condition(:updating_name_disabled_for_users) do - ::Gitlab::CurrentSettings.current_application_settings - .updating_name_disabled_for_users - end - rule { ~restricted_public_level }.enable :read_user rule { ~anonymous }.enable :read_user @@ -27,8 +22,8 @@ class UserPolicy < BasePolicy enable :update_user_status end - rule { can?(:update_user) & ( admin | ~updating_name_disabled_for_users ) }.enable :update_name - rule { default }.enable :read_user_profile rule { (private_profile | blocked_user) & ~(user_is_self | admin) }.prevent :read_user_profile end + +UserPolicy.prepend_if_ee('EE::UserPolicy') |