r89896 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89895‎ | r89896 | r89897 >
Date:21:40, 11 June 2011
Author:foxtrott
Status:deferred
Tags:
Comment:
use returned ParserOutput from MessageLog
Modified paths:
  • /trunk/extensions/SemanticGlossary/SpecialSemanticGlossaryBrowser.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticGlossary/SpecialSemanticGlossaryBrowser.php
@@ -110,10 +110,13 @@
111111 }
112112
113113 // From here on no more errors should occur. Create list of errors.
114 - $errorsFragment = $this->mMessages->getMessagesFormatted( LingoMessageLog::MESSAGE_NOTICE, wfMsg( 'semanticglossary-messageheader' ) );
 114+ $errors = $this->mMessages->getMessagesFormatted( LingoMessageLog::MESSAGE_NOTICE, wfMsg( 'semanticglossary-messageheader' ) );
115115
116 - if ( $errorsFragment ) {
117 - $errorsFragment .= Html::rawElement( 'hr' );
 116+ if ( $errors !== null ) {
 117+ $wgOut->addParserOutputNoText( $errors );
 118+ $errorsFragment = $errors->getText() . Html::rawElement( 'hr' );
 119+ } else {
 120+ $errorsFragment = '';
118121 }
119122
120123 if ( $hasEditRights ) {