Improve code style
This commit is contained in:
parent
e4aebad35a
commit
927333f4f8
41 changed files with 126 additions and 122 deletions
|
@ -3,11 +3,9 @@ class Api::V1::FollowsController < ApiController
|
|||
respond_to :json
|
||||
|
||||
def create
|
||||
if params[:uri].blank?
|
||||
raise ActiveRecord::RecordNotFound
|
||||
end
|
||||
raise ActiveRecord::RecordNotFound if params[:uri].blank?
|
||||
|
||||
@account = FollowService.new.(current_user.account, params[:uri]).try(:target_account)
|
||||
@account = FollowService.new.call(current_user.account, params[:uri]).try(:target_account)
|
||||
render action: :show
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue