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:
authorJames Lopez <james@jameslopez.es>2017-06-22 13:10:28 +0300
committerJames Lopez <james@jameslopez.es>2017-06-23 12:41:42 +0300
commit0ee002c70ea3711046b8d254b5cba044762e9c05 (patch)
treefe61f06a538f4d43e36ce5d68f8627cb51ceb5e8 /app/controllers/profiles/avatars_controller.rb
parent4c75fe5dfe898b7c4882c88364df936460891e2a (diff)
more refactoring
Diffstat (limited to 'app/controllers/profiles/avatars_controller.rb')
-rw-r--r--app/controllers/profiles/avatars_controller.rb4
1 files changed, 1 insertions, 3 deletions
diff --git a/app/controllers/profiles/avatars_controller.rb b/app/controllers/profiles/avatars_controller.rb
index cab9ea24270..851885d2224 100644
--- a/app/controllers/profiles/avatars_controller.rb
+++ b/app/controllers/profiles/avatars_controller.rb
@@ -2,9 +2,7 @@ class Profiles::AvatarsController < Profiles::ApplicationController
def destroy
@user = current_user
- Users::UpdateService.new(@user, @user).execute do |user|
- user.remove_avatar!
- end
+ Users::UpdateService.new(@user, @user).execute { |user| user.remove_avatar! }
redirect_to profile_path, status: 302
end