From 12184972ae1f01b3977001f71777ab724a455cdb Mon Sep 17 00:00:00 2001 From: Krenair Date: Sat, 20 Oct 2012 15:46:01 +0100 Subject: [PATCH] (bug 41242) Parse the unacceptable new account name/move messages Caused by Ie78fa258 Also fix blacklist validation message and add a missing whitespace Change-Id: I8be6bded76a048cba1d8770f795ef240b7b02951 --- TitleBlacklist.hooks.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/TitleBlacklist.hooks.php b/TitleBlacklist.hooks.php index cf0740cc..b03c5645 100644 --- a/TitleBlacklist.hooks.php +++ b/TitleBlacklist.hooks.php @@ -60,7 +60,7 @@ class TitleBlacklistHooks { $err = wfMessage( $blacklisted->getErrorMessage( 'move' ), $blacklisted->getRaw(), $old->getFullText(), - $nt->getFullText() )->escaped(); + $nt->getFullText() )->parse(); return false; } return true; @@ -80,7 +80,7 @@ class TitleBlacklistHooks { 'new-account', $override ); if ( $blacklisted instanceof TitleBlacklistEntry ) { $message = $blacklisted->getErrorMessage( 'new-account' ); - $err = wfMessage( $message, $blacklisted->getRaw(), $userName )->escaped(); + $err = wfMessage( $message, $blacklisted->getRaw(), $userName )->parse(); return false; } return true; @@ -109,7 +109,7 @@ class TitleBlacklistHooks { * * @param $editor EditPage */ - public static function validateBlacklist( $editor, $text, $section, $error ) { + public static function validateBlacklist( $editor, $text, $section, &$error ) { global $wgUser; $title = $editor->mTitle; @@ -122,7 +122,7 @@ class TitleBlacklistHooks { return true; } - $errmsg = wfMessage( 'titleblacklist-invalid')->numParams( count( $ok ) )->text(); + $errmsg = wfMessage( 'titleblacklist-invalid' )->numParams( count( $ok ) )->text(); $errlines = '* ' . implode( "\n* ", array_map( 'wfEscapeWikiText', $ok ) ) . ''; $error = Html::openElement( 'div', array( 'class' => 'errorbox' ) ) . $errmsg .