Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/admin/users_controller.rb')
-rw-r--r--app/controllers/admin/users_controller.rb9
1 files changed, 7 insertions, 2 deletions
diff --git a/app/controllers/admin/users_controller.rb b/app/controllers/admin/users_controller.rb
index f05b03c2787..1f05e4e7b21 100644
--- a/app/controllers/admin/users_controller.rb
+++ b/app/controllers/admin/users_controller.rb
@@ -221,8 +221,7 @@ class Admin::UsersController < Admin::ApplicationController
respond_to do |format|
result = Users::UpdateService.new(current_user, user_params_with_pass.merge(user: user)).execute do |user|
- user.skip_reconfirmation!
- user.send_only_admin_changed_your_password_notification! if admin_making_changes_for_another_user?
+ prepare_user_for_update(user)
end
if result[:status] == :success
@@ -393,6 +392,12 @@ class Admin::UsersController < Admin::ApplicationController
@can_impersonate = helpers.can_impersonate_user(user, impersonation_in_progress?)
@impersonation_error_text = @can_impersonate ? nil : helpers.impersonation_error_text(user, impersonation_in_progress?)
end
+
+ # method overriden in EE
+ def prepare_user_for_update(user)
+ user.skip_reconfirmation!
+ user.send_only_admin_changed_your_password_notification! if admin_making_changes_for_another_user?
+ end
end
Admin::UsersController.prepend_mod_with('Admin::UsersController')