Fix: 投稿にNGワードが含まれる場合、投稿のモデレーションができなくなる場合がある問題 (#685)

This commit is contained in:
KMY(雪あすか) 2024-04-01 08:54:16 +09:00 committed by GitHub
parent 4a9f549dd2
commit e7aececf5e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 23 additions and 8 deletions

View file

@ -83,7 +83,7 @@ class Admin::StatusBatchAction
authorize([:admin, status], :update?)
if target_account.local?
UpdateStatusService.new.call(status, representative_account.id, sensitive: true)
UpdateStatusService.new.call(status, representative_account.id, sensitive: true, bypass_validation: true)
else
status.update(sensitive: true)
end
@ -119,7 +119,7 @@ class Admin::StatusBatchAction
status_text = "#{status.spoiler_text}\n\n#{status_text}" if status.spoiler_text
if target_account.local?
UpdateStatusService.new.call(status, representative_account.id, spoiler_text: 'CW', text: status_text)
UpdateStatusService.new.call(status, representative_account.id, spoiler_text: 'CW', text: status_text, bypass_validation: true)
else
status.update(spoiler_text: 'CW', text: status_text)
end