2016-09-27 23:58:23 +09:00
|
|
|
class Api::V1::FollowsController < ApiController
|
2016-03-12 00:47:36 +09:00
|
|
|
before_action :doorkeeper_authorize!
|
2016-03-07 20:42:33 +09:00
|
|
|
respond_to :json
|
|
|
|
|
|
|
|
def create
|
2016-09-30 04:28:21 +09:00
|
|
|
raise ActiveRecord::RecordNotFound if params[:uri].blank?
|
2016-09-13 02:20:55 +09:00
|
|
|
|
2016-09-30 04:28:21 +09:00
|
|
|
@account = FollowService.new.call(current_user.account, params[:uri]).try(:target_account)
|
2016-03-07 20:42:33 +09:00
|
|
|
render action: :show
|
|
|
|
end
|
|
|
|
end
|