From 3f1d78f3c6ac8d4ad5d41fe5f1bcdbccde4c2d7a Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 27 Aug 2025 08:50:16 -0400 Subject: [PATCH] Use target account from `group_by` result in admin/reports/index (#35920) --- app/views/admin/reports/index.html.haml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/views/admin/reports/index.html.haml b/app/views/admin/reports/index.html.haml index 44664b85fd9..e08218a05d9 100644 --- a/app/views/admin/reports/index.html.haml +++ b/app/views/admin/reports/index.html.haml @@ -30,8 +30,7 @@ %button.button= t('admin.accounts.search') = link_to t('admin.accounts.reset'), admin_reports_path, class: 'button button--dangerous' -- @reports.group_by(&:target_account_id).each_value do |reports| - - target_account = reports.first.target_account +- @reports.group_by(&:target_account).each do |target_account, reports| .report-card .report-card__profile = account_link_to target_account, '', path: admin_account_path(target_account.id)