return Status::newGood();
}
+ /**
+ * Insert Main Page with default content.
+ *
+ * @return Status
+ */
+ public function installMainpage( DatabaseInstaller &$installer ) {
+ $status = Status::newGood();
+ try {
+ $titleobj = Title::newFromText( wfMsgNoDB( "mainpage" ) );
+ $article = new Article( $titleobj );
+ $article->doEdit( wfMsg( 'mainpagetext' ) . "\n\n" . wfMsgNoTrans( 'mainpagedocfooter' ),
+ '',
+ EDIT_NEW );
+ } catch (MWException $e) {
+ //using raw, because $wgShowExceptionDetails can not be set yet
+ $status->fatal( 'config-install-mainpage-failed', $e->getMessage() );
+ }
+
+ return $status;
+ }
+
/**
* Override the necessary bits of the config to run an installation.
*/
return $status;
}
- /**
- * Insert Main Page with default content.
- *
- * @return Status
- */
- public function createMainpage() {
- $status = Status::newGood();
- try {
- $titleobj = Title::newFromText( wfMsgNoDB( "mainpage" ) );
- $article = new Article( $titleobj );
- $article->doEdit( wfMsg( 'mainpagetext' ) . "\n\n" . wfMsgNoTrans( 'mainpagedocfooter' ),
- '',
- EDIT_NEW );
- } catch (MWException $e) {
- //using raw, because $wgShowExceptionDetails can not be set yet
- $status->fatal( 'config-install-mainpage-failed', $e->getMessage() );
- }
-
- return $status;
- }
-
/**
* Get the DBMS-specific options for LocalSettings.php generation.
*
return $installer->populateInterwikiTable();
}
- /**
- * TODO: document
- *
- * @param $installer DatabaseInstaller
- *
- * @return Status
- */
- public function installMainpage( DatabaseInstaller &$installer ) {
- return $installer->createMainpage();
- }
-
/**
* Exports all wg* variables stored by the installer into global scope.
*/