$noRC = $this->hasOption( 'no-rc' );
$wgUser = User::newFromName( $userName );
- $context = RequestContext::getMain();
- $context->setUser( $wgUser );
if ( !$wgUser ) {
$this->error( "Invalid username", true );
}
if ( !$title ) {
$this->error( "Invalid title", true );
}
- $context->setTitle( $title );
if ( $this->hasOption( 'nocreate' ) && !$title->exists() ) {
$this->error( "Page does not exist", true );
foreach ( $res as $row ) {
$titleA = Title::makeTitle( $row->pa_namespace, $row->pa_title );
$titleB = Title::makeTitle( $row->pb_namespace, $row->pb_title );
- RequestContext::getMain()->setTitle( $titleA );
$processedTitles .= "* [[$titleA]]\n";