Merge "Accessor to get EditPage parent revision ID"
[lhc/web/wiklou.git] / includes / installer / DatabaseInstaller.php
index 1c15ad0..752450f 100644 (file)
@@ -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;
        }
 
        /**
@@ -644,10 +649,10 @@ abstract class DatabaseInstaller {
                        return $status;
                }
                global $IP;
-               wfSuppressWarnings();
+               MediaWiki\suppressWarnings();
                $rows = file( "$IP/maintenance/interwiki.list",
                        FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES );
-               wfRestoreWarnings();
+               MediaWiki\restoreWarnings();
                $interwikis = array();
                if ( !$rows ) {
                        return Status::newFatal( 'config-install-interwiki-list' );