$status = Status::newFatal( 'movepage-max-pages', $wgMaximumMovedPages );
$perTitleStatus[$oldSubpage->getPrefixedText()] = $status;
$topStatus->merge( $status );
- $topStatus->setOk( true );
+ $topStatus->setOK( true );
break;
}
}
$perTitleStatus[$oldSubpage->getPrefixedText()] = $status;
$topStatus->merge( $status );
- $topStatus->setOk( true );
+ $topStatus->setOK( true );
}
$topStatus->value = $perTitleStatus;
$method = $auth ? 'moveSubpagesIfAllowed' : 'moveSubpages';
$result = $mp->$method( $wgUser, $reason, $createRedirect, $changeTags );
- if ( !$result->isOk() ) {
+ if ( !$result->isOK() ) {
return $result->getErrorsArray();
}
$mp = new MovePage( $fromTitle, $toTitle );
$result =
$mp->moveSubpagesIfAllowed( $this->getUser(), $reason, !$noredirect, $changeTags );
- if ( !$result->isOk() ) {
+ if ( !$result->isOK() ) {
// This means the whole thing failed
return [ 'errors' => $this->getErrorFormatter()->arrayFromStatus( $result ) ];
}
// PerformInstallation bails on a fatal, so make sure the last item
// completed before giving 'next.' Likewise, only provide back on failure
$lastStepStatus = end( $result );
- if ( $lastStepStatus->isOk() ) {
+ if ( $lastStepStatus->isOK() ) {
return Status::newGood();
} else {
return $lastStepStatus;
// If we've hit some sort of fatal, we need to bail.
// Callback already had a chance to do output above.
- if ( !$status->isOk() ) {
+ if ( !$status->isOK() ) {
break;
}
}
- if ( $status->isOk() ) {
+ if ( $status->isOK() ) {
$this->showMessage(
'config-install-db-success'
);
// When constructing this class for submitting to the queue,
// normalise the $title arg of old job classes as part of $params.
$params['namespace'] = $title->getNamespace();
- $params['title'] = $title->getDBKey();
+ $params['title'] = $title->getDBkey();
}
$this->command = $command;
}
// Always attempt to call teardown() even if Job throws exception.
try {
- $job->teardown( $status );
+ $job->tearDown( $status );
} catch ( Exception $e ) {
MWExceptionHandler::logException( $e );
}
'error' => '',
];
- if ( !$sv->isOk() ) {
+ if ( !$sv->isOK() ) {
$svErrors = $sv->getErrors();
if ( isset( $svErrors[0] ) ) {
$req['response']['error'] = $svErrors[0]['message'];
$mp = new MovePage( $oldSubpage, $newSubpage );
# This was copy-pasted from Renameuser, bleh.
- if ( $newSubpage->exists() && !$mp->isValidMove()->isOk() ) {
+ if ( $newSubpage->exists() && !$mp->isValidMove()->isOK() ) {
$link = $linkRenderer->makeKnownLink( $newSubpage );
$extraOutput[] = $this->msg( 'movepage-page-exists' )->rawParams( $link )->escaped();
} else {
}
$status = StatusValue::newGood();
- $status->setOk( false );
+ $status->setOK( false );
try {
$mock->dieStatus( $status );
$this->fail( 'Expected exception not thrown' );
$req->email = $email;
$req->realname = $realname;
$this->assertEquals( $expect, $req->populateUser( $user ) );
- if ( $expect->isOk() ) {
+ if ( $expect->isOK() ) {
$this->assertSame( $email ?: 'default@example.com', $user->getEmail() );
$this->assertSame( $realname ?: 'Fake Name', $user->getRealName() );
}
$restriction = $restrictions[0];
$this->assertEquals( $page->getId(), $restriction->getValue() );
$this->assertEquals( $page->getId(), $restriction->getTitle()->getArticleID() );
- $this->assertEquals( $title->getDBKey(), $restriction->getTitle()->getDBKey() );
+ $this->assertEquals( $title->getDBkey(), $restriction->getTitle()->getDBkey() );
$this->assertEquals( $title->getNamespace(), $restriction->getTitle()->getNamespace() );
// Delete the block and the restrictions.