aboutsummaryrefslogtreecommitdiffstats
path: root/includes/logging
diff options
context:
space:
mode:
authorUmherirrender <umherirrender_de.wp@web.de>2020-12-07 15:26:40 +0100
committerUmherirrender <umherirrender_de.wp@web.de>2020-12-07 16:04:57 +0000
commit3857415e7e6738bede9b83a71c6b2835c80344a4 (patch)
treebd89a90d98cf53dc1ffb81fe35ea7ed93ae4af86 /includes/logging
parent38ee9bc7bfb5c3d54010397d0e5277e313cdcedf (diff)
downloadmediawikicore-3857415e7e6738bede9b83a71c6b2835c80344a4.tar.gz
mediawikicore-3857415e7e6738bede9b83a71c6b2835c80344a4.zip
Pass escaped html to LogFormatter::makePageLink for sanity
Bug: T268938 Change-Id: Ib6847d56eb2d1c19f695f50327c9a58d8d8603da
Diffstat (limited to 'includes/logging')
-rw-r--r--includes/logging/BlockLogFormatter.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/logging/BlockLogFormatter.php b/includes/logging/BlockLogFormatter.php
index 5394b79b58c1..0a6a2f30e469 100644
--- a/includes/logging/BlockLogFormatter.php
+++ b/includes/logging/BlockLogFormatter.php
@@ -86,8 +86,8 @@ class BlockLogFormatter extends LogFormatter {
$namespaces = $params[6]['namespaces'] ?? [];
$namespaces = array_map( function ( $ns ) {
$text = (int)$ns === NS_MAIN
- ? $this->msg( 'blanknamespace' )->text()
- : $this->context->getLanguage()->getFormattedNsText( $ns );
+ ? $this->msg( 'blanknamespace' )->escaped()
+ : htmlspecialchars( $this->context->getLanguage()->getFormattedNsText( $ns ) );
$params = [ 'namespace' => $ns ];
return $this->makePageLink( SpecialPage::getTitleFor( 'Allpages' ), $params, $text );