r52621 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r52620‎ | r52621 | r52622 >
Date:08:52, 1 July 2009
Author:thomasv
Status:deferred
Tags:
Comment:
simplification: removing unneeded parameter
Modified paths:
  • /trunk/extensions/ProofreadPage/ProofreadPage.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ProofreadPage/ProofreadPage.php
@@ -124,7 +124,7 @@
125125 function pr_navigation( $title ) {
126126 global $pr_page_namespace, $pr_index_namespace;
127127
128 - $err = array( '', '', '', '', '', array() );
 128+ $err = array( '', '', '', '', '' );
129129
130130 $index_title = Title::newFromText( $title->pr_index_title );
131131 $imageTitle = Title::makeTitleSafe( NS_IMAGE, $index_title->getText() );
@@ -158,13 +158,13 @@
159159 }
160160
161161 if ( !$index_title ) {
162 - return array( '', $prev_url, $next_url, '', '', array() ) ;
 162+ return array( '', $prev_url, $next_url, '', '' ) ;
163163 }
164164
165165 $index_url = $index_title->getFullURL();
166166
167167 if ( !$index_title->exists() ) {
168 - return array( $index_url, $prev_url, $next_url, '', '', array() );
 168+ return array( $index_url, $prev_url, $next_url, '', '' );
169169 }
170170
171171 //if the index page exists, find current page number, previous and next pages
@@ -200,7 +200,7 @@
201201 $footer = str_replace( "{{{{$key}}}}", $val, $footer );
202202 }
203203
204 - return array( $index_url, $prev_url, $next_url, $header, $footer, $attributes );
 204+ return array( $index_url, $prev_url, $next_url, $header, $footer );
205205
206206 }
207207
@@ -341,7 +341,7 @@
342342 $thumbURL = '';
343343 }
344344
345 - list( $index_url, $prev_url, $next_url, $header, $footer, $attributes ) = pr_navigation( $wgTitle );
 345+ list( $index_url, $prev_url, $next_url, $header, $footer ) = pr_navigation( $wgTitle );
346346
347347 $jsFile = htmlspecialchars( "$wgScriptPath/extensions/ProofreadPage/proofread.js?$wgProofreadPageVersion" );
348348
@@ -354,11 +354,9 @@
355355 'proofreadPageIndexURL' => $index_url,
356356 'proofreadPagePrevURL' => $prev_url,
357357 'proofreadPageNextURL' => $next_url,
358 - ) + $attributes;
359 -
360 - $jsVars['proofreadPageHeader'] = $header;
361 - $jsVars['proofreadPageFooter'] = $footer;
362 -
 358+ 'proofreadPageHeader' => $header,
 359+ 'proofreadPageFooter' => $footer,
 360+ );
363361 $varScript = Skin::makeVariablesScript( $jsVars );
364362
365363 $out->addScript( <<<EOT
@@ -781,7 +779,7 @@
782780 //convert to page format
783781 $username = $wgUser->getName();
784782 pr_load_index( $title );
785 - list( $index_url, $prev_url, $next_url, $header, $footer, $attributes ) = pr_navigation( $title );
 783+ list( $index_url, $prev_url, $next_url, $header, $footer ) = pr_navigation( $title );
786784 $editpage->textbox1 =
787785 "<noinclude>{{PageQuality|1|$username}}$header\n\n\n</noinclude>"
788786 .$text."<noinclude>\n$footer</noinclude>";

Status & tagging log