Fix exception from list=recentchanges rcprop=loginfo: update for new log system
authorTim Starling <tstarling@users.mediawiki.org>
Tue, 28 Feb 2012 00:14:33 +0000 (00:14 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Tue, 28 Feb 2012 00:14:33 +0000 (00:14 +0000)
includes/api/ApiQueryRecentChanges.php

index 7ddf670..0ce5b37 100644 (file)
@@ -423,13 +423,14 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                        $vals['logid'] = intval( $row->rc_logid );
                        $vals['logtype'] = $row->rc_log_type;
                        $vals['logaction'] = $row->rc_log_action;
+                       $logEntry = DatabaseLogEntry::newFromRow( (array)$row );
                        ApiQueryLogEvents::addLogParams(
                                $this->getResult(),
                                $vals,
-                               $row->rc_params,
-                               $row->rc_log_action,
-                               $row->rc_log_type,
-                               $row->rc_timestamp
+                               $logEntry->getParameters(),
+                               $logEntry->getType(),
+                               $logEntry->getSubtype(),
+                               $logEntry->getTimestamp()
                        );
                }