common_cli and dbal: Fixed lack of ENANO_INSTALLED check in determining config path
authorDan
Tue, 01 Dec 2009 00:27:26 -0500
changeset 1143 e271ae801c62
parent 1142 c522ea3871a3
child 1144 fcb2be1428e7
common_cli and dbal: Fixed lack of ENANO_INSTALLED check in determining config path
includes/common_cli.php
includes/dbal.php
--- a/includes/common_cli.php	Mon Nov 30 22:35:14 2009 -0500
+++ b/includes/common_cli.php	Tue Dec 01 00:27:26 2009 -0500
@@ -30,7 +30,7 @@
 // even be installed. If this connection attempt fails and it's because of a missing or corrupt config file, the
 // user will be redirected (intelligently) to install.php.
 
-$config_file = ( defined('IN_ENANO_INSTALL') ) ? '/config.new.php' : '/config.php';
+$config_file = ( defined('IN_ENANO_INSTALL') && !defined('ENANO_INSTALLED') ) ? '/config.new.php' : '/config.php';
 @include(ENANO_ROOT . $config_file);
 unset($dbuser, $dbpasswd);
 if ( !isset($dbdriver) )
--- a/includes/dbal.php	Mon Nov 30 22:35:14 2009 -0500
+++ b/includes/dbal.php	Tue Dec 01 00:27:26 2009 -0500
@@ -157,7 +157,7 @@
     
     if ( !$manual_credentials )
     {
-      if ( defined('IN_ENANO_INSTALL') && !defined('IN_ENANO_UPGRADE') )
+      if ( defined('IN_ENANO_INSTALL') && !defined('IN_ENANO_UPGRADE') && !defined('ENANO_INSTALLED') )
       {
         @include(ENANO_ROOT.'/config.new.php');
       }