*/
function initialize( &$title, &$article, &$output, &$user, $request ) {
wfProfileIn( __METHOD__ );
- $this->preliminaryChecks( $title, $output, $request ) ;
+ $this->preliminaryChecks( $title, $output, $request );
if( !$this->initializeSpecialCases( $title, $output, $request ) ) {
$new_article = $this->initializeArticle( $title, $request );
if( is_object( $new_article ) ) {
* @param $request WebRequest
*/
function preliminaryChecks( &$title, &$output, $request ) {
-
if( $request->getCheck( 'search' ) ) {
// Compatibility with old search URLs which didn't use Special:Search
// Just check for presence here, so blank requests still
// Do this above the read whitelist check for security...
$title = SpecialPage::getTitleFor( 'Search' );
}
-
# If the user is not logged in, the Namespace:title of the article must be in
# the Read array in order for the user to see it. (We have to check here to
# catch special pages etc. We check again in Article::view())
$output->output();
exit;
}
-
}
/**
$dbr = wfGetDB( DB_SLAVE );
$article->loadPageData( $article->pageDataFromTitle( $dbr, $title ) );
- wfRunHooks( 'InitializeArticleMaybeRedirect', array( &$title, &$request, &$ignoreRedirect, &$target ) );
+ wfRunHooks( 'InitializeArticleMaybeRedirect',
+ array(&$title,&$request,&$ignoreRedirect,&$target,&$article) );
// Follow redirects only for... redirects
if( !$ignoreRedirect && $article->isRedirect() ) {