r45178 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r45177‎ | r45178 | r45179 >
Date:08:38, 30 December 2008
Author:aaron
Status:deferred
Tags:
Comment:
Remove unused parameters
Modified paths:
  • /trunk/extensions/FlaggedRevs/FlaggedRevision.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/FlaggedRevs.class.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/specialpages/RevisionReview_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/FlaggedRevs.class.php
@@ -268,10 +268,9 @@
269269 * @param Article $article
270270 * @param string $text
271271 * @param int $id
272 - * @param bool $reparsed (is this being reparsed from fr_text?)
273272 * @return ParserOutput
274273 */
275 - public static function parseStableText( $article, $text='', $id, $reparsed = true ) {
 274+ public static function parseStableText( $article, $text='', $id ) {
276275 global $wgParser;
277276 $title = $article->getTitle(); // avoid pass-by-reference error
278277 # Make our hooks trigger (force unstub so setting doesn't get lost)
Index: trunk/extensions/FlaggedRevs/FlaggedRevision.php
@@ -8,7 +8,7 @@
99 private $mQuality;
1010 private $mTags;
1111 private $mText = null;
12 - private $mRawDBText, $mFlags;
 12+ private $mFlags;
1313 private $mUser;
1414 private $mRevision;
1515 private $mFileName, $mFileSha1, $mFileTimestamp;
@@ -33,7 +33,6 @@
3434 $this->mTitle = isset($row->page_namespace) && isset($row->page_title) ?
3535 Title::makeTitleSafe( $row->page_namespace, $row->page_title ) : null;
3636 $this->mFlags = isset($row->fr_flags) ? explode(',',$row->fr_flags) : null;
37 - $this->mRawDBText = isset($row->fr_text) ? $row->fr_text : null;
3837 } else if( is_array($row) ) {
3938 $this->mRevId = intval( $row['fr_rev_id'] );
4039 $this->mPageId = intval( $row['fr_page_id'] );
@@ -48,7 +47,6 @@
4948 $this->mUser = intval( $row['fr_user'] );
5049 # Optional fields
5150 $this->mFlags = isset($row['fr_flags']) ? explode(',',$row['fr_flags']) : null;
52 - $this->mRawDBText = isset($row['fr_text']) ? $row['fr_text'] : null;
5351 } else {
5452 throw new MWException( 'FlaggedRevision constructor passed invalid row format.' );
5553 }
@@ -200,7 +198,6 @@
201199 public function insertOn( $fulltext, $tmpRows, $fileRows ) {
202200 # Store/compress text as needed, and get the flags
203201 $textFlags = FlaggedRevision::doSaveCompression( $fulltext );
204 - $this->mRawDBText = $fulltext; // wikitext or ES url
205202 $this->mFlags = explode(',',$textFlags);
206203 $dbw = wfGetDB( DB_MASTER );
207204 # Our review entry
Index: trunk/extensions/FlaggedRevs/specialpages/RevisionReview_body.php
@@ -559,7 +559,7 @@
560560 return $err;
561561 }
562562 # Parse the rest and check if it matches up
563 - $stableOutput = FlaggedRevs::parseStableText( $article, $fulltext, $rev->getId(), false );
 563+ $stableOutput = FlaggedRevs::parseStableText( $article, $fulltext, $rev->getId() );
564564 $err =& $stableOutput->fr_includeErrors;
565565 if( !$noMatch && (!empty($err) || $stableOutput->fr_newestImageTime > $lastImgTime) ) {
566566 wfProfileOut( __METHOD__ );

Status & tagging log