From f02411da404f730e3c05dc7dca1ac0f2d631315e Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Mon, 19 Mar 2018 01:51:19 +0100 Subject: [PATCH] Ignore media validation when attaching to status during processing (#6822) Fix #6821 --- app/lib/activitypub/activity/create.rb | 2 +- app/lib/ostatus/activity/creation.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/lib/activitypub/activity/create.rb b/app/lib/activitypub/activity/create.rb index 5a1c13d678..676e885c0b 100644 --- a/app/lib/activitypub/activity/create.rb +++ b/app/lib/activitypub/activity/create.rb @@ -53,7 +53,7 @@ class ActivityPub::Activity::Create < ActivityPub::Activity visibility: visibility_from_audience, thread: replied_to_status, conversation: conversation_from_uri(@object['conversation']), - media_attachments: process_attachments.take(4), + media_attachment_ids: process_attachments.take(4).map(&:id), } end diff --git a/app/lib/ostatus/activity/creation.rb b/app/lib/ostatus/activity/creation.rb index aa46267dc7..6235127b20 100644 --- a/app/lib/ostatus/activity/creation.rb +++ b/app/lib/ostatus/activity/creation.rb @@ -45,7 +45,7 @@ class OStatus::Activity::Creation < OStatus::Activity::Base visibility: visibility_scope, conversation: find_or_create_conversation, thread: thread? ? find_status(thread.first) || find_activitypub_status(thread.first, thread.second) : nil, - media_attachments: media_attachments + media_attachment_ids: media_attachments.map(&:id) ) save_mentions(status)