diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2022-05-26 22:04:16 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-26 22:04:16 +0200 |
commit | 976cd6413e9b2a1531a2ad17945342deaeec538c (patch) | |
tree | 1b301443fe5b9e57a7d719762c3d2caffbe655ad | |
parent | 9f81b9f29a14093cefcdbf09058ace089cd8e06b (diff) |
Fix moderator leak in undo_mark_statuses_as_sensitive (#18525)
Signed-off-by: Eugen Rochko <eugen@zeonfederated.com> Co-authored-by: 40826d <74816220+40826d@users.noreply.github.com>
-rw-r--r-- | app/services/approve_appeal_service.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/services/approve_appeal_service.rb b/app/services/approve_appeal_service.rb index 37a08b46e..96aaaa7d0 100644 --- a/app/services/approve_appeal_service.rb +++ b/app/services/approve_appeal_service.rb @@ -52,8 +52,9 @@ class ApproveAppealService < BaseService end def undo_mark_statuses_as_sensitive! + representative_account = Account.representative @strike.statuses.includes(:media_attachments).each do |status| - UpdateStatusService.new.call(status, @current_account.id, sensitive: false) if status.with_media? + UpdateStatusService.new.call(status, representative_account.id, sensitive: false) if status.with_media? end end |