Fixed reverting of database code

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@42998 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Andrew O'Neil 2007-10-03 00:10:03 +00:00
parent 4d9e93460d
commit fda211156a

View File

@ -174,19 +174,13 @@ class ManifestBuilder {
$manifest .= "\$_CSS_MANIFEST = " . var_export($cssManifest, true) . ";\n";
DB::connect($databaseConfig);
if(DB::isActive()) {
// Database manifest
$allClasses = ManifestBuilder::allClasses($classManifest);
$manifest .= "\$_ALL_CLASSES = " . var_export($allClasses, true) . ";\n";
global $_ALL_CLASSES;
$_ALL_CLASSES = $allClasses;
} else {
if(!isset($_REQUEST['from_installer']))
echo '<li>Waiting until the database is created before compiling ' .
'the manifest</li>';
}
// Database manifest
$allClasses = ManifestBuilder::allClasses($classManifest);
$manifest .= "\$_ALL_CLASSES = " . var_export($allClasses, true) . ";\n";
global $_ALL_CLASSES;
$_ALL_CLASSES = $allClasses;
// Write manifest to disk
$manifest = "<?php\n$manifest\n?>";