about summary refs log tree commit diff
path: root/app/controllers/api
diff options
context:
space:
mode:
authorSurinna Curtis <ekiru.0@gmail.com>2017-09-13 18:32:10 -0500
committerSurinna Curtis <ekiru.0@gmail.com>2017-09-13 21:47:30 -0500
commitf9d7b8a94f4a89d76081a6265103f6d7439be250 (patch)
tree6e91787f0181b1b7ec3e658f2ee35710e2071aaa /app/controllers/api
parent211f0a951375a33ed4278eef030e76a6bde9c396 (diff)
Refactor handling of default params for muting to make code cleaner
Diffstat (limited to 'app/controllers/api')
-rw-r--r--app/controllers/api/v1/accounts_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/api/v1/accounts_controller.rb b/app/controllers/api/v1/accounts_controller.rb
index de2cb0d97..3e9ac1025 100644
--- a/app/controllers/api/v1/accounts_controller.rb
+++ b/app/controllers/api/v1/accounts_controller.rb
@@ -33,7 +33,7 @@ class Api::V1::AccountsController < Api::BaseController
   end
 
   def mute
-    MuteService.new.call(current_user.account, @account, **params.permit(:notifications).to_hash.symbolize_keys)
+    MuteService.new.call(current_user.account, @account, notifications: params(:notifications))
     render json: @account, serializer: REST::RelationshipSerializer, relationships: relationships
   end