* In CoreInstaller, fixed notice when extensions are present, due to incorrect format...
authorTim Starling <tstarling@users.mediawiki.org>
Fri, 19 Nov 2010 01:31:16 +0000 (01:31 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Fri, 19 Nov 2010 01:31:16 +0000 (01:31 +0000)
* In LocalSettingsGenerator, fixed PHP escaping of extension name.

includes/installer/CoreInstaller.php
includes/installer/LocalSettingsGenerator.php

index acdef84..24b410c 100644 (file)
@@ -314,7 +314,7 @@ abstract class CoreInstaller extends Installer {
                );
                if( count( $this->getVar( '_Extensions' ) ) ) {
                        array_unshift( $installSteps, 
-                               array( 'extensions', array( $this, 'includeExtensions' ) )
+                               array( 'name' => 'extensions', 'callback' => array( $this, 'includeExtensions' ) )
                        );
                }
                foreach( $installSteps as $idx => $stepObj ) {
index 820729d..e3eb957 100644 (file)
@@ -112,8 +112,9 @@ class LocalSettingsGenerator {
                if( count( $this->extensions ) ) {
                        $localSettings .= "\n# The following extensions were automatically enabled:\n";
                        
-                       foreach( $this->extensions as $ext ) {
-                               $localSettings .= "require( 'extensions/$ext/$ext.php' );\n";
+                       foreach( $this->extensions as $extName ) {
+                               $encExtName = self::escapePhpString( $extName );
+                               $localSettings .= "require( \"extensions/$encExtName/$encExtName.php\" );\n";
                        }
                }