diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-05-01 15:30:02 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-05-01 15:30:02 -0400 |
commit | 1de335ad3f395ca6861085393ba366a9e3fb4a0d (patch) | |
tree | f1fdd326034e05177596851be6a7127615d81498 /includes/installer/DatabaseInstaller.php | |
parent | 9c75fa8ff6d4d38ef552c00fef5969fb154765e8 (diff) | |
parent | f6d65e533c62f6deb21342d4901ece24497b433e (diff) |
Merge commit 'f6d65'
# Conflicts:
# skins/ArchLinux/ArchLinux.php
Diffstat (limited to 'includes/installer/DatabaseInstaller.php')
-rw-r--r-- | includes/installer/DatabaseInstaller.php | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/includes/installer/DatabaseInstaller.php b/includes/installer/DatabaseInstaller.php index 31b93c88..6ccf2d55 100644 --- a/includes/installer/DatabaseInstaller.php +++ b/includes/installer/DatabaseInstaller.php @@ -305,7 +305,7 @@ abstract class DatabaseInstaller { $up = DatabaseUpdater::newForDB( $this->db ); try { $up->doUpdates(); - } catch ( MWException $e ) { + } catch ( Exception $e ) { echo "\nAn error occurred:\n"; echo $e->getText(); $ret = false; @@ -369,12 +369,17 @@ abstract class DatabaseInstaller { } /** - * Get a name=>value map of MW configuration globals that overrides. - * DefaultSettings.php + * Get a name=>value map of MW configuration globals for the default values. * @return array */ public function getGlobalDefaults() { - return array(); + $defaults = array(); + foreach ( $this->getGlobalNames() as $var ) { + if ( isset( $GLOBALS[$var] ) ) { + $defaults[$var] = $GLOBALS[$var]; + } + } + return $defaults; } /** @@ -657,7 +662,7 @@ abstract class DatabaseInstaller { if ( $row == "" ) { continue; } - $row .= "||"; + $row .= "|"; $interwikis[] = array_combine( array( 'iw_prefix', 'iw_url', 'iw_local', 'iw_api', 'iw_wikiid' ), explode( '|', $row ) |