X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin/?a=blobdiff_plain;f=includes%2Fchanges%2FRecentChange.php;h=159cfd93de318dcfad3fffd2311f1138361b082a;hb=fd42f6c8486e27d7f386e2467b5c92a30371a2bf;hp=2508304ce15dbecf829dc0c50cb177cea641fd38;hpb=bdc24ab7a3235a18af53d67e21b00fbfa36e72d8;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/changes/RecentChange.php b/includes/changes/RecentChange.php index 2508304ce1..159cfd93de 100644 --- a/includes/changes/RecentChange.php +++ b/includes/changes/RecentChange.php @@ -851,7 +851,9 @@ class RecentChange { 'rc_logid' => 0, 'rc_log_type' => null, 'rc_log_action' => '', - 'rc_params' => '' + 'rc_params' => serialize( [ + 'hidden-cat' => WikiCategoryPage::factory( $categoryTitle )->isHidden() + ] ) ]; $rc->mExtra = [ @@ -865,6 +867,19 @@ class RecentChange { return $rc; } + /** + * Get a parameter value + * + * @since 1.27 + * + * @param string $name parameter name + * @return mixed + */ + public function getParam( $name ) { + $params = $this->parseParams(); + return isset( $params[$name] ) ? $params[$name] : null; + } + /** * Initialises the members of this object from a mysql row object * @@ -973,7 +988,7 @@ class RecentChange { * * @since 1.26 * - * @return array|null + * @return mixed|bool false on failed unserialization */ public function parseParams() { $rcParams = $this->getAttribute( 'rc_params' );