From d60ff22b75a85a477ce668be70f7c79491f0a285 Mon Sep 17 00:00:00 2001 From: Siebrand Mazeland Date: Tue, 3 Dec 2013 22:41:33 +0100 Subject: [PATCH] Declare visibility on log class related properties Also add a few missing ones. Change-Id: Iff1d9ebc79f8990bfa2e3c4eea2ff15a7c9cd55e --- includes/logging/LogEntry.php | 8 ++++++++ includes/logging/LogPage.php | 23 +++++++++++++++-------- 2 files changed, 23 insertions(+), 8 deletions(-) diff --git a/includes/logging/LogEntry.php b/includes/logging/LogEntry.php index 19d970755e..00991360c5 100644 --- a/includes/logging/LogEntry.php +++ b/includes/logging/LogEntry.php @@ -176,6 +176,11 @@ class DatabaseLogEntry extends LogEntryBase { /** @var User */ protected $performer; + /** @var bool Whether the parameters for this log entry are stored in new + * or old format. + */ + protected $legacy; + protected function __construct( $row ) { $this->row = $row; } @@ -361,6 +366,9 @@ class ManualLogEntry extends LogEntryBase { /** @var int Deletion state of the log entry */ protected $deleted; + /** @var int ID of the log entry */ + protected $id; + /** * Constructor. * diff --git a/includes/logging/LogPage.php b/includes/logging/LogPage.php index 46accb5cbd..7e5d09e801 100644 --- a/includes/logging/LogPage.php +++ b/includes/logging/LogPage.php @@ -40,31 +40,37 @@ class LogPage { const SUPPRESSED_ACTION = 9; /** @var bool */ - var $updateRecentChanges; + public $updateRecentChanges; /** @var bool */ - var $sendToUDP; + public $sendToUDP; + + /** @var string Plaintext version of the message for IRC */ + private $ircActionText; + + /** @var string Plaintext version of the message */ + private $actionText; /** @var string One of '', 'block', 'protect', 'rights', 'delete', * 'upload', 'move' */ - var $type; + private $type; /** @var string One of '', 'block', 'protect', 'rights', 'delete', * 'upload', 'move', 'move_redir' */ - var $action; + private $action; /** @var string Comment associated with action */ - var $comment; + private $comment; /** @var string Blob made of a parameters array */ - var $params; + private $params; /** @var User The user doing the action */ - var $doer; + private $doer; /** @var Title */ - var $target; + private $target; /** * Constructor @@ -89,6 +95,7 @@ class LogPage { $dbw = wfGetDB( DB_MASTER ); $log_id = $dbw->nextSequenceValue( 'logging_log_id_seq' ); + // @todo FIXME private/protected/public property? $this->timestamp = $now = wfTimestampNow(); $data = array( 'log_id' => $log_id, -- 2.20.1