From 0c08780ca248c6b76cba9661f08575932d400a91 Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Sat, 27 Apr 2024 19:29:50 -0600 Subject: [PATCH] Update database.php --- resources/classes/database.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/resources/classes/database.php b/resources/classes/database.php index 732caca5e8..d2741bc980 100644 --- a/resources/classes/database.php +++ b/resources/classes/database.php @@ -272,7 +272,7 @@ * Singleton type class * @var database */ - private $database; + private static $database; /** * Called when the object is created @@ -3080,9 +3080,9 @@ * @see database::__construct() * @see database::connect() */ - public static function new() { - if (self::$database === null) - self::$database = new database(); + public static function new(array $params = []) { + if (self::$database === null) { + self::$database = new database($params); self::$database->connect(); } return self::$database;