From 9c697f082c973b60da23b05fdae4814f23cb51a6 Mon Sep 17 00:00:00 2001 From: albertlast Date: Sat, 8 Aug 2026 18:40:01 +0200 Subject: [PATCH] Drops the two moderation blocks nothing renders ReportedContent.template.php carries template_reported_posts_block() and template_reported_members_block(). Neither is reachable: the moderation centre home is the only thing that asks for blocks, it registers reported_posts_block and reported_users_block, and it loads ModerationCenter.template.php, which supplies both. ReportedContent.php loads this file and only ever sets reported_posts, reported_members, viewmodreport, viewmemberreport or edit_comment. The copy of template_reported_posts_block() here is an older one, still building its list from mc_reportedp_subject_author and report_href where the live one uses mc_post_report and report_link. Because both files define the same function, anything that got them loaded in the same request - a mod adding a block, an integration hook - would fatal on the redeclaration rather than pick one. template_reported_members_block() is where the undefined mc_recent_member_reports string was, so that goes with it. Signed-off-by: Mathias Papenbrock Signed-off-by: albertlast --- Themes/default/ReportedContent.template.php | 138 -------------------- 1 file changed, 138 deletions(-) diff --git a/Themes/default/ReportedContent.template.php b/Themes/default/ReportedContent.template.php index 25bd6edb75f..4d9a741cb18 100644 --- a/Themes/default/ReportedContent.template.php +++ b/Themes/default/ReportedContent.template.php @@ -107,75 +107,6 @@ function template_reported_posts() '; } -/** - * A block to show the current top reported posts. - */ -function template_reported_posts_block() -{ - echo ' - -
-
-
    '; - - foreach (Utils::$context['reported_posts'] as $report) { - echo ' -
  • - ', Lang::getTxt('mc_reportedp_subject_author', ['subject' => '' . $report['subject'] . '', 'author' => $report['author']['link']], file: 'ModerationCenter'), ' -
  • '; - } - - // Don't have any watched users right now? - if (empty(Utils::$context['reported_posts'])) { - echo ' -
  • - ', Lang::getTxt('mc_recent_reports_none', file: 'ModerationCenter'), ' -
  • '; - } - - echo ' -
-
-
- - '; -} - /** * Handles viewing details of and managing a specific report */ @@ -326,75 +257,6 @@ function template_edit_comment() '; } -/** - * A block to show the current top reported member profiles. - */ -function template_reported_members_block() -{ - echo ' - -
-
-
    '; - - foreach (Utils::$context['reported_members'] as $report) { - echo ' -
  • - ', $report['user_name'], ' -
  • '; - } - - // Don't have any reported members right now? - if (empty(Utils::$context['reported_members'])) { - echo ' -
  • - ', Lang::getTxt('mc_recent_reports_none', file: 'ModerationCenter'), ' -
  • '; - } - - echo ' -
-
-
- - '; -} - /** * Lists all reported members */