r55734 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r55733‎ | r55734 | r55735 >
Date:22:32, 1 September 2009
Author:yaron
Status:deferred
Tags:
Comment:
Fixed handling for params to #get_external_data that should contain a '=' but don't
Modified paths:
  • /trunk/extensions/ExternalData/ED_ParserFunctions.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ExternalData/ED_ParserFunctions.php
@@ -76,11 +76,14 @@
7777 // set to all lowercase to avoid casing issues
7878 $external_var = strtolower( $external_var );
7979 $filters[$external_var] = $value;
80 - } else {
 80+ } elseif ( strpos( $param, '=' ) ) {
8181 list( $local_var, $external_var ) = explode( '=', $param );
8282 // set to all lowercase to avoid casing issues
8383 $external_var = strtolower( $external_var );
8484 $mappings[$local_var] = $external_var;
 85+ } else {
 86+ // if the parameter contains no equals signs,
 87+ // do nothing
8588 }
8689 }
8790 foreach ( $filters as $filter_var => $filter_value ) {

Status & tagging log