From: Alexandre Emsenhuber Date: Mon, 19 Dec 2011 16:05:47 +0000 (+0000) Subject: * Inlinise the only usage of $user in MediaWiki::main() X-Git-Tag: 1.31.0-rc.0~25899 X-Git-Url: https://git.cyclocoop.org/%7B%24admin_url%7Dmembres/cotisations/rappels.php?a=commitdiff_plain;h=9717e5cb18c05c20351986c612fbb46529c20e8d;p=lhc%2Fweb%2Fwiklou.git * Inlinise the only usage of $user in MediaWiki::main() * Change the name of the variable containing the WikiPage object for more consistency --- diff --git a/includes/Wiki.php b/includes/Wiki.php index 2a3444eeb3..4984b5f0ca 100644 --- a/includes/Wiki.php +++ b/includes/Wiki.php @@ -583,7 +583,6 @@ class MediaWiki { # Set title from request parameters $wgTitle = $this->getTitle(); $action = $this->getAction(); - $user = $this->context->getUser(); # Send Ajax requests to the Ajax dispatcher. if ( $wgUseAjax && $action == 'ajax' ) { @@ -605,8 +604,8 @@ class MediaWiki { $cache->loadFromFileCache( $this->context ); } # Do any stats increment/watchlist stuff - $article = WikiPage::factory( $this->getTitle() ); - $article->doViewUpdates( $user ); + $page = WikiPage::factory( $this->getTitle() ); + $page->doViewUpdates( $this->context->getUser() ); # Tell OutputPage that output is taken care of $this->context->getOutput()->disable(); wfProfileOut( 'main-try-filecache' );