Missed two of the $db connections.

This commit is contained in:
markjcrane
2016-04-14 23:05:05 -06:00
parent 8392bdeafa
commit e9415fd26c
+14 -2
View File
@@ -449,7 +449,13 @@ function save_gateway_xml() {
} }
function save_module_xml() { function save_module_xml() {
global $config, $db, $domain_uuid; global $config, $domain_uuid;
//get the database connection
require_once "resources/classes/database.php";
$database = new database;
$database->connect();
$db = $database->db;
$xml = ""; $xml = "";
$xml .= "<configuration name=\"modules.conf\" description=\"Modules\">\n"; $xml .= "<configuration name=\"modules.conf\" description=\"Modules\">\n";
@@ -487,7 +493,13 @@ function save_module_xml() {
} }
function save_var_xml() { function save_var_xml() {
global $config, $db, $domain_uuid; global $config, $domain_uuid;
//get the database connection
require_once "resources/classes/database.php";
$database = new database;
$database->connect();
$db = $database->db;
//open the vars.xml file //open the vars.xml file
$fout = fopen($_SESSION['switch']['conf']['dir']."/vars.xml","w"); $fout = fopen($_SESSION['switch']['conf']['dir']."/vars.xml","w");