Merge "Use {{int:}} on MediaWiki:Blockedtext and MediaWiki:Autoblockedtext"
[lhc/web/wiklou.git] / includes / logging / PatrolLog.php
index f6ecc50..9b2e098 100644 (file)
@@ -27,6 +27,7 @@
  * logs of patrol events
  */
 class PatrolLog {
+
        /**
         * Record a log event for a change being patrolled
         *
@@ -39,10 +40,8 @@ class PatrolLog {
         * @return bool
         */
        public static function record( $rc, $auto = false, User $user = null, $tags = null ) {
-               global $wgLogAutopatrol;
-
-               // do not log autopatrolled edits if setting disables it
-               if ( $auto && !$wgLogAutopatrol ) {
+               // Do not log autopatrol actions: T184485
+               if ( $auto ) {
                        return false;
                }
 
@@ -58,7 +57,9 @@ class PatrolLog {
                        $user = $wgUser;
                }
 
-               $entry = new ManualLogEntry( 'patrol', 'patrol' );
+               $action = $auto ? 'autopatrol' : 'patrol';
+
+               $entry = new ManualLogEntry( 'patrol', $action );
                $entry->setTarget( $rc->getTitle() );
                $entry->setParameters( self::buildParams( $rc, $auto ) );
                $entry->setPerformer( $user );