r103144 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r103143‎ | r103144 | r103145 >
Date:10:52, 15 November 2011
Author:aaron
Status:ok
Tags:
Comment:
Replaced echo()/print statements with $this->output()
Modified paths:
  • /trunk/extensions/FlaggedRevs/maintenance/flagToSemiProtect.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/maintenance/pruneRevData.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/maintenance/updateTracking.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/maintenance/flagToSemiProtect.php
@@ -119,7 +119,6 @@
120120 $article = new WikiPage( $title );
121121 $ok = $article->updateRestrictions( $limit, $reason, $cascade, $expiry, $user );
122122 if ( $ok ) {
123 - #echo $title->getPrefixedText() . "\n\t[" . implode( ', ', $desc ) . "]\n";
124123 $count++;
125124 } else {
126125 $this->output( "Could not protect: " . $title->getPrefixedText() . "\n" );
Index: trunk/extensions/FlaggedRevs/maintenance/pruneRevData.php
@@ -43,7 +43,7 @@
4444 }
4545 $end = $db->selectField( 'flaggedpages', 'MAX(fp_page_id)', false, __METHOD__ );
4646 if ( is_null( $start ) || is_null( $end ) ) {
47 - echo "...flaggedpages table seems to be empty.\n";
 47+ $this->output( "...flaggedpages table seems to be empty.\n" );
4848 return;
4949 }
5050 $end += $this->mBatchSize - 1; # Do remaining chunk
Index: trunk/extensions/FlaggedRevs/maintenance/updateTracking.php
@@ -38,7 +38,7 @@
3939 $this->update_flaggedimages( $startRev );
4040 break;
4141 default:
42 - echo "Invalidate operation specified.\n";
 42+ $this->error( "Invalidate operation specified.\n", true );
4343 }
4444 } else {
4545 $this->update_flaggedrevs( $startRev );

Status & tagging log