From 2045b52af18a0c21d9708cb6cbd77ea38f0908b9 Mon Sep 17 00:00:00 2001 From: dis45927 Date: Tue, 15 Mar 2016 10:30:33 +0000 Subject: [PATCH] Fix bug preventing mysql database creation --- core/install/resources/classes/install_fusionpbx.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/install/resources/classes/install_fusionpbx.php b/core/install/resources/classes/install_fusionpbx.php index 2cdd85b44e..4325ff9fae 100644 --- a/core/install/resources/classes/install_fusionpbx.php +++ b/core/install/resources/classes/install_fusionpbx.php @@ -426,10 +426,10 @@ include "root.php"; } //create the table, user and set the permissions only if the db_create_username was provided - if ($this->global_settings->db_create()) { + if ($this->global_settings->db_create_username()) { $this->write_progress("\tCreating database"); try { - $this->dbh = new PDO($connect_string, $this->global_settings->db_create_username(), db_create_password, array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8')); + $this->dbh = new PDO($connect_string, $this->global_settings->db_create_username(), $this->global_settings->db_create_password(), array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8')); $this->dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); $this->dbh->setAttribute(PDO::ATTR_EMULATE_PREPARES, true); }