r72503 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r72502‎ | r72503 | r72504 >
Date:18:28, 6 September 2010
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Follow up to r72497
Modified paths:
  • /trunk/extensions/Validator/includes/Validator.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Validator/includes/Validator.php
@@ -296,10 +296,12 @@
297297 public function formatParameters() {
298298 foreach ( $this->parameters as $parameter ) {
299299 foreach ( $parameter->outputTypes as $outputType ) {
 300+ $outputType[0] = strtolower( $outputType[0] );
300301 if ( array_key_exists( $outputType[0], self::$mOutputFormats ) ) {
301302 $parameters = array( &$parameter->value, $parameter->getName(), $this->parameters );
302 - $parameters = array_merge( $parameters, $arguments );
303 - call_user_func_array( self::$mOutputFormats[$outputType[0]], $parameters );
 303+ $name = array_shift( $outputType );
 304+ $parameters = array_merge( $parameters, $outputType );
 305+ call_user_func_array( self::$mOutputFormats[$name], $parameters );
304306 }
305307 else {
306308 throw new Exception( 'There is no formatting function for output format ' . $outputType[0] );

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r72497Changes for 0.7 - matching changes made in Validatorjeroendedauw16:17, 6 September 2010

Status & tagging log