r83853 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r83852‎ | r83853 | r83854 >
Date:21:17, 13 March 2011
Author:reedy
Status:ok
Tags:
Comment:
Documentation
Modified paths:
  • /trunk/phase3/includes/LogEventsList.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/LogEventsList.php
@@ -27,10 +27,27 @@
2828 const NO_ACTION_LINK = 1;
2929 const NO_EXTRA_USER_LINKS = 2;
3030
 31+ /**
 32+ * @var Skin
 33+ */
3134 private $skin;
 35+
 36+ /**
 37+ * @var OutputPage
 38+ */
3239 private $out;
3340 public $flags;
3441
 42+ /**
 43+ * @var Array
 44+ */
 45+ protected $message;
 46+
 47+ /**
 48+ * @var Array
 49+ */
 50+ protected $mDefaultQuery;
 51+
3552 public function __construct( $skin, $out, $flags = 0 ) {
3653 $this->skin = $skin;
3754 $this->out = $out;
@@ -82,8 +99,7 @@
83100 * @param $tagFilter: array?
84101 */
85102 public function showOptions( $types=array(), $user='', $page='', $pattern='', $year='',
86 - $month = '', $filter = null, $tagFilter='' )
87 - {
 103+ $month = '', $filter = null, $tagFilter='' ) {
88104 global $wgScript, $wgMiserMode;
89105
90106 $action = $wgScript;
@@ -357,7 +373,15 @@
358374 return $comment;
359375 }
360376
361 - // @TODO: split up!
 377+ /**
 378+ * @TODO: split up!
 379+ *
 380+ * @param $row
 381+ * @param Title $title
 382+ * @param Array $paramArray
 383+ * @param $comment
 384+ * @return String
 385+ */
362386 private function logActionLinks( $row, $title, $paramArray, &$comment ) {
363387 global $wgUser;
364388 if( ( $this->flags & self::NO_ACTION_LINK ) // we don't want to see the action
@@ -506,8 +530,7 @@
507531 private function getShowHideLinks( $row ) {
508532 global $wgUser;
509533 if( ( $this->flags & self::NO_ACTION_LINK ) // we don't want to see the links
510 - || $row->log_type == 'suppress' ) // no one can hide items from the suppress log
511 - {
 534+ || $row->log_type == 'suppress' ) { // no one can hide items from the suppress log
512535 return '';
513536 }
514537 $del = '';
@@ -758,8 +781,7 @@
759782 * @param $tagFilter String: tag
760783 */
761784 public function __construct( $list, $types = array(), $user = '', $title = '', $pattern = '',
762 - $conds = array(), $year = false, $month = false, $tagFilter = '' )
763 - {
 785+ $conds = array(), $year = false, $month = false, $tagFilter = '' ) {
764786 parent::__construct();
765787 $this->mConds = $conds;
766788
@@ -878,8 +900,9 @@
879901 global $wgMiserMode, $wgUser;
880902
881903 $title = Title::newFromText( $page );
882 - if( strlen( $page ) == 0 || !$title instanceof Title )
 904+ if( strlen( $page ) == 0 || !$title instanceof Title ) {
883905 return false;
 906+ }
884907
885908 $this->title = $title->getPrefixedText();
886909 $ns = $title->getNamespace();

Status & tagging log