r91365 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r91364‎ | r91365 | r91366 >
Date:18:42, 2 July 2011
Author:aaron
Status:ok
Tags:
Comment:
Follow-up r91363: we need a msg key on failure
Modified paths:
  • /trunk/extensions/FlaggedRevs/business/RevisionReviewForm.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/business/RevisionReviewForm.php
@@ -310,9 +310,12 @@
311311 $editStatus = $article->doEdit(
312312 $new_text, $this->getComment(), 0, $baseRevId, $this->user );
313313
314 - $status = $editStatus->isOK();
 314+ $status = $editStatus->isOK() ? true : 'review_cannot_undo';
315315 # If this undid one edit by another logged-in user, update user tallies
316 - if ( $status && $newRev->getParentId() == $oldRev->getId() && $newRev->getRawUser() ) {
 316+ if ( $status === true
 317+ && $newRev->getParentId() == $oldRev->getId()
 318+ && $newRev->getRawUser() )
 319+ {
317320 if ( $newRev->getRawUser() != $this->user->getId() ) { // no self-reverts
318321 FRUserCounters::incCount( $newRev->getRawUser(), 'revertedEdits' );
319322 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r92317REL1_18 FR: r87606, r87617, r87669, r87690, r87700, r90388, r90419, r90741, r...reedy21:53, 15 July 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r91363Fixed bogus reference to $status var (causes a msg exception later down)aaron18:32, 2 July 2011

Status & tagging log