diff options
author | Reverite <github@reverite.sh> | 2019-06-09 16:54:21 -0700 |
---|---|---|
committer | Reverite <github@reverite.sh> | 2019-06-09 16:54:21 -0700 |
commit | 3614718bc91f90a6dc19dd80ecf3bc191283c24e (patch) | |
tree | ad35f4dbe92fdbc3f95881d6be3d4f9b29d4a704 /app/models/form/account_batch.rb | |
parent | 846a09a7435fb9eb435e9950175ee0e696ed4909 (diff) | |
parent | e16c8fbc7a2b5a866960a87bc8c950ad0d38f61b (diff) |
Merge branch 'glitch' into production
Diffstat (limited to 'app/models/form/account_batch.rb')
-rw-r--r-- | app/models/form/account_batch.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/app/models/form/account_batch.rb b/app/models/form/account_batch.rb index 5bc44e809..f1b7a4566 100644 --- a/app/models/form/account_batch.rb +++ b/app/models/form/account_batch.rb @@ -3,6 +3,7 @@ class Form::AccountBatch include ActiveModel::Model include Authorization + include Payloadable attr_accessor :account_ids, :action, :current_account @@ -54,13 +55,7 @@ class Form::AccountBatch return unless follow.account.activitypub? - json = ActiveModelSerializers::SerializableResource.new( - follow, - serializer: ActivityPub::RejectFollowSerializer, - adapter: ActivityPub::Adapter - ).to_json - - ActivityPub::DeliveryWorker.perform_async(json, current_account.id, follow.account.inbox_url) + ActivityPub::DeliveryWorker.perform_async(Oj.dump(serialize_payload(follow, ActivityPub::RejectFollowSerializer)), current_account.id, follow.account.inbox_url) end def approve! |