diff --git a/workflow/engine/classes/class.Installer.php b/workflow/engine/classes/class.Installer.php index e3a27c160..3350aa6d3 100755 --- a/workflow/engine/classes/class.Installer.php +++ b/workflow/engine/classes/class.Installer.php @@ -198,7 +198,7 @@ class Installer $db_text = "options['database']['hostname'] . ":" . $myPort . "' );\n" . "define ('DB_NAME', '" . $wf . "' );\n" . "define ('DB_USER', '" . (($this->cc_status == 1) ? $wf : $this->options['database']['username']) . "' );\n" . "define ('DB_PASS', '" . (($this->cc_status == 1) ? $this->options['password'] : $this->options['database']['password']) . "' );\n" . "define ('DB_RBAC_HOST', '" . $this->options['database']['hostname'] . ":" . $myPort . "' );\n" . "define ('DB_RBAC_NAME', '" . $rb . "' );\n" . "define ('DB_RBAC_USER', '" . (($this->cc_status == 1) ? $rb : $this->options['database']['username']) . "' );\n" . "define ('DB_RBAC_PASS', '" . (($this->cc_status == 1) ? $this->options['password'] : $this->options['database']['password']) . "' );\n" . "define ('DB_REPORT_HOST', '" . $this->options['database']['hostname'] . ":" . $myPort . "' );\n" . "define ('DB_REPORT_NAME', '" . $rp . "' );\n" . "define ('DB_REPORT_USER', '" . (($this->cc_status == 1) ? $rp : $this->options['database']['username']) . "' );\n" . "define ('DB_REPORT_PASS', '" . (($this->cc_status == 1) ? $this->options['password'] : $this->options['database']['password']) . "' );\n" . "?>"; if (defined('PARTNER_FLAG') || isset($_REQUEST['PARTNER_FLAG'])) { $dbText .= "define ('PARTNER_FLAG', " . ((defined('PARTNER_FLAG')) ? PARTNER_FLAG : ((isset($_REQUEST['PARTNER_FLAG'])) ? $_REQUEST['PARTNER_FLAG']:'false')) . ");\n"; - if (!defined('SYSTEM_NAME')) { + if (defined('SYSTEM_NAME')) { $dbText .= " define ('SYSTEM_NAME', " . SYSTEM_NAME . ");\n"; } } diff --git a/workflow/engine/controllers/installer.php b/workflow/engine/controllers/installer.php index a469632c1..491cf8f7f 100644 --- a/workflow/engine/controllers/installer.php +++ b/workflow/engine/controllers/installer.php @@ -690,7 +690,7 @@ class Installer extends Controller if (defined('PARTNER_FLAG') || isset($_REQUEST['PARTNER_FLAG'])) { $dbText .= "\n"; $dbText .= " define ('PARTNER_FLAG', " . ((defined('PARTNER_FLAG')) ? PARTNER_FLAG : ((isset($_REQUEST['PARTNER_FLAG'])) ? $_REQUEST['PARTNER_FLAG']:'false')) . ");\n"; - $systemName = $this->getNameSystem($pathShared); + $systemName = $this->getNameSystem(); if ($systemName != '') { $dbText .= " define ('SYSTEM_NAME', " . $systemName . ");\n"; } diff --git a/workflow/engine/controllers/main.php b/workflow/engine/controllers/main.php index dd6d33731..7775d623b 100644 --- a/workflow/engine/controllers/main.php +++ b/workflow/engine/controllers/main.php @@ -734,7 +734,7 @@ class Main extends Controller $properties = array (); $ee = class_exists( 'pmLicenseManager' ) ? " - Enterprise Edition" : ''; $systemName = 'ProcessMaker'; - if (!defined('SYSTEM_NAME')) { + if (defined('SYSTEM_NAME')) { $systemName = SYSTEM_NAME; } $properties[] = array ($systemName. ' Ver.', System::getVersion() . $ee, $pmSection);