aboutsummaryrefslogtreecommitdiffstats
path: root/includes/CommentFormatter
diff options
context:
space:
mode:
authorJames D. Forrester <jforrester@wikimedia.org>2023-09-19 17:59:47 +0100
committerDannyS712 <dannys712.wiki@gmail.com>2023-09-21 05:39:23 +0000
commit468e69bccc409129499e9848a6a4d8764b5be468 (patch)
treeb245019f0379aa38d055f2bc5153c79185472b17 /includes/CommentFormatter
parentfa034d2ad7d2788616f5ae3d582621ba0f2cc1f1 (diff)
downloadmediawikicore-468e69bccc409129499e9848a6a4d8764b5be468.tar.gz
mediawikicore-468e69bccc409129499e9848a6a4d8764b5be468.zip
Namespace Sanitizer under \MediaWiki\Parser
Bug: T166010 Change-Id: Id13dcbf7a0372017495958dbc4f601f40c122508
Diffstat (limited to 'includes/CommentFormatter')
-rw-r--r--includes/CommentFormatter/CommentParser.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/includes/CommentFormatter/CommentParser.php b/includes/CommentFormatter/CommentParser.php
index 802f2e93dd5d..455d714f89fc 100644
--- a/includes/CommentFormatter/CommentParser.php
+++ b/includes/CommentFormatter/CommentParser.php
@@ -13,6 +13,7 @@ use MediaWiki\HookContainer\HookRunner;
use MediaWiki\Linker\Linker;
use MediaWiki\Linker\LinkRenderer;
use MediaWiki\Linker\LinkTarget;
+use MediaWiki\Parser\Sanitizer;
use MediaWiki\Title\MalformedTitleException;
use MediaWiki\Title\NamespaceInfo;
use MediaWiki\Title\Title;
@@ -172,7 +173,7 @@ class CommentParser {
$comment = strtr( $comment, "\n\x1b", " " );
// Allow HTML entities (for T15815)
if ( !$unsafe ) {
- $comment = \Sanitizer::escapeHtmlAllowEntities( $comment );
+ $comment = Sanitizer::escapeHtmlAllowEntities( $comment );
}
if ( $enableSectionLinks ) {
$comment = $this->doSectionLinks( $comment, $selfLinkTarget, $samePage, $wikiId );