2
0

Fix deletion of posts quoting soft-deleted local post (#36461)

This commit is contained in:
Claire
2025-10-14 17:15:38 +02:00
committed by GitHub
parent 3232eee358
commit fd516347cb
2 changed files with 21 additions and 0 deletions

View File

@@ -129,4 +129,20 @@ RSpec.describe RemoveStatusService, :inline_jobs do
)
)
end
context 'when removed status is a quote of a local user', inline_jobs: false do
let(:original_status) { Fabricate(:status, account: alice) }
let(:status) { Fabricate(:status, account: jeff) }
before do
bill.follow!(jeff)
Fabricate(:quote, status: status, quoted_status: original_status, state: :accepted)
original_status.discard
end
it 'sends deletion without crashing' do
expect { subject.call(status.reload) }
.to enqueue_sidekiq_job(ActivityPub::DeliveryWorker).with(/Delete/, jeff.id, bill.inbox_url)
end
end
end