Move merging/unmerging of timelines into background. Move blocking into
background as well since it's a computationally expensive
This commit is contained in:
@ -65,8 +65,13 @@ class Api::V1::AccountsController < ApiController
|
||||
end
|
||||
|
||||
def block
|
||||
BlockService.new.call(current_user.account, @account)
|
||||
set_relationship
|
||||
BlockWorker.perform_async(current_user.account_id, @account.id)
|
||||
|
||||
@following = { @account.id => false }
|
||||
@followed_by = { @account.id => false }
|
||||
@blocking = { @account.id => true }
|
||||
@requested = { @account.id => false }
|
||||
|
||||
render action: :relationship
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user