* Change: #375 投稿を編集して拡張ドメインブロックの条件にひっかかる状態になった場合、対象サーバーには投稿削除のActivityを送信する * Fix test * Add test
This commit is contained in:
parent
e4375143ca
commit
fcd13a6474
8 changed files with 146 additions and 12 deletions
|
@ -24,6 +24,7 @@ class UpdateStatusService < BaseService
|
|||
@account_id = account_id
|
||||
@media_attachments_changed = false
|
||||
@poll_changed = false
|
||||
@old_sensitive = sensitive?
|
||||
|
||||
clear_histories! if @options[:no_history]
|
||||
|
||||
|
@ -189,7 +190,7 @@ class UpdateStatusService < BaseService
|
|||
|
||||
def broadcast_updates!
|
||||
DistributionWorker.perform_async(@status.id, { 'update' => true })
|
||||
ActivityPub::StatusUpdateDistributionWorker.perform_async(@status.id)
|
||||
ActivityPub::StatusUpdateDistributionWorker.perform_async(@status.id, { 'sensitive' => sensitive?, 'sensitive_changed' => @old_sensitive != sensitive? && sensitive? })
|
||||
end
|
||||
|
||||
def queue_poll_notifications!
|
||||
|
@ -227,4 +228,8 @@ class UpdateStatusService < BaseService
|
|||
@status.edited_at = nil
|
||||
@status.save!
|
||||
end
|
||||
|
||||
def sensitive?
|
||||
@status.sensitive
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue