r111965 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r111964‎ | r111965 | r111966 >
Date:21:36, 20 February 2012
Author:mah
Status:resolved
Tags:
Comment:
fix bug #34495 — patrol log credit the user patrolled, not the user patrolling
Modified paths:
  • /trunk/phase3/includes/logging/PatrolLog.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/logging/PatrolLog.php
@@ -27,10 +27,12 @@
2828
2929 $title = Title::makeTitleSafe( $rc->getAttribute( 'rc_namespace' ), $rc->getAttribute( 'rc_title' ) );
3030 if( $title ) {
 31+ global $wgUser;
 32+
3133 $entry = new ManualLogEntry( 'patrol', 'patrol' );
3234 $entry->setTarget( $title );
3335 $entry->setParameters( self::buildParams( $rc, $auto ) );
34 - $entry->setPerformer( User::newFromName( $rc->getAttribute( 'rc_user_text' ), false ) );
 36+ $entry->setPerformer( $wgUser, false ) );
3537 $logid = $entry->insert();
3638 if ( !$auto ) {
3739 $entry->publish( $logid, 'udp' );

Sign-offs

UserFlagDate
Nikerabbitinspected08:41, 21 February 2012

Follow-up revisions

RevisionCommit summaryAuthorDate
r111967Fix parse error from r111965ialex21:39, 20 February 2012
r111969MFT to 1.19wmf1 r111965 r11967...hashar21:49, 20 February 2012
r112024MFT r111658, r111965, r111966, r111967, r112021reedy17:07, 21 February 2012

Status & tagging log