- wfRunHooks( 'BeforeInitialize',
- array( &$title, null, &$output, &$user, $request, $this ) );
+ $unused = null; // To pass it by reference
+ wfRunHooks( 'BeforeInitialize', array( &$title, &$unused, &$output, &$user, $request, $this ) );
// Invalid titles. Bug 21776: The interwikis must redirect even if the page name is empty.
if ( is_null( $title ) || ( $title->getDBkey() == '' && $title->getInterwiki() == '' ) ||
// Invalid titles. Bug 21776: The interwikis must redirect even if the page name is empty.
if ( is_null( $title ) || ( $title->getDBkey() == '' && $title->getInterwiki() == '' ) ||
// We will check again in Article::view().
$permErrors = $title->getUserPermissionsErrors( 'read', $user );
if ( count( $permErrors ) ) {
// We will check again in Article::view().
$permErrors = $title->getUserPermissionsErrors( 'read', $user );
if ( count( $permErrors ) ) {
- // Bug 32276: allowing the skin to generate output with $wgTitle or
- // $this->context->title set to the input title would allow anonymous users to
- // determine whether a page exists, potentially leaking private data. In fact, the
- // curid and oldid request parameters would allow page titles to be enumerated even
- // when they are not guessable. So we reset the title to Special:Badtitle before the
+ // Bug 32276: allowing the skin to generate output with $wgTitle or
+ // $this->context->title set to the input title would allow anonymous users to
+ // determine whether a page exists, potentially leaking private data. In fact, the
+ // curid and oldid request parameters would allow page titles to be enumerated even
+ // when they are not guessable. So we reset the title to Special:Badtitle before the
# Set title from request parameters
$wgTitle = $this->getTitle();
$action = $this->getAction();
# Set title from request parameters
$wgTitle = $this->getTitle();
$action = $this->getAction();
wfProfileIn( 'main-try-filecache' );
if ( HTMLFileCache::useFileCache( $this->context ) ) {
/* Try low-level file cache hit */
wfProfileIn( 'main-try-filecache' );
if ( HTMLFileCache::useFileCache( $this->context ) ) {
/* Try low-level file cache hit */
if ( $cache->isCacheGood( /* Assume up to date */ ) ) {
/* Check incoming headers to see if client has this cached */
$timestamp = $cache->cacheTimestamp();
if ( $cache->isCacheGood( /* Assume up to date */ ) ) {
/* Check incoming headers to see if client has this cached */
$timestamp = $cache->cacheTimestamp();
# Tell OutputPage that output is taken care of
$this->context->getOutput()->disable();
wfProfileOut( 'main-try-filecache' );
# Tell OutputPage that output is taken care of
$this->context->getOutput()->disable();
wfProfileOut( 'main-try-filecache' );