r70812 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r70811‎ | r70812 | r70813 >
Date:12:55, 10 August 2010
Author:reedy
Status:ok
Tags:
Comment:
Fix fixme placed on r30022 by me (fixing per comment)

Adding a few braces too
Modified paths:
  • /trunk/phase3/includes/parser/Preprocessor_DOM.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/parser/Preprocessor_DOM.php
@@ -1136,7 +1136,9 @@
11371137 $first = true;
11381138 $s = '';
11391139 foreach ( $args as $root ) {
1140 - if ( $root instanceof PPNode_DOM ) $root = $root->node;
 1140+ if ( $root instanceof PPNode_DOM ) {
 1141+ $root = $root->node;
 1142+ }
11411143 if ( !is_array( $root ) && !( $root instanceof DOMNodeList ) ) {
11421144 $root = array( $root );
11431145 }
@@ -1160,9 +1162,11 @@
11611163 $args = array_slice( func_get_args(), 1 );
11621164 $out = array();
11631165 $first = true;
1164 - if ( $root instanceof PPNode_DOM ) $root = $root->node;
11651166
11661167 foreach ( $args as $root ) {
 1168+ if ( $root instanceof PPNode_DOM ) {
 1169+ $root = $root->node;
 1170+ }
11671171 if ( !is_array( $root ) && !( $root instanceof DOMNodeList ) ) {
11681172 $root = array( $root );
11691173 }
@@ -1187,7 +1191,9 @@
11881192 $first = true;
11891193
11901194 foreach ( $args as $root ) {
1191 - if ( $root instanceof PPNode_DOM ) $root = $root->node;
 1195+ if ( $root instanceof PPNode_DOM ) {
 1196+ $root = $root->node;
 1197+ }
11921198 if ( !is_array( $root ) && !( $root instanceof DOMNodeList ) ) {
11931199 $root = array( $root );
11941200 }

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r30022Postcard from linuxland....tstarling16:36, 21 January 2008

Status & tagging log