diff options
author | James Lopez <james@jameslopez.es> | 2017-06-22 13:10:28 +0300 |
---|---|---|
committer | James Lopez <james@jameslopez.es> | 2017-06-23 12:41:42 +0300 |
commit | 0ee002c70ea3711046b8d254b5cba044762e9c05 (patch) | |
tree | fe61f06a538f4d43e36ce5d68f8627cb51ceb5e8 /app/controllers/profiles/avatars_controller.rb | |
parent | 4c75fe5dfe898b7c4882c88364df936460891e2a (diff) |
more refactoring
Diffstat (limited to 'app/controllers/profiles/avatars_controller.rb')
-rw-r--r-- | app/controllers/profiles/avatars_controller.rb | 4 |
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 |