From 44283dbbbb30d434f1153df7e09b62f54b22887d Mon Sep 17 00:00:00 2001 From: redmatrix Date: Thu, 31 Mar 2016 20:24:30 -0700 Subject: [PATCH] change the App constructor --- boot.php | 2 +- include/cli_startup.php | 5 +---- index.php | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/boot.php b/boot.php index 07c427e10..f480dd46d 100755 --- a/boot.php +++ b/boot.php @@ -784,7 +784,7 @@ class App { /** * App constructor. */ - function __construct() { + function init() { // we'll reset this after we read our config file date_default_timezone_set('UTC'); diff --git a/include/cli_startup.php b/include/cli_startup.php index 9fcdce199..b0e4fcf10 100644 --- a/include/cli_startup.php +++ b/include/cli_startup.php @@ -12,10 +12,7 @@ function cli_startup() { $a = new miniApp; } - if(is_null($app)) { - $app = new App; - } - + App::init(); if(is_null($db)) { @include(".htconfig.php"); diff --git a/index.php b/index.php index c4b47f6a8..a6ed3dbc6 100755 --- a/index.php +++ b/index.php @@ -19,7 +19,7 @@ if(file_exists('.htsite.php')) $a = new miniApp; -$app = new App; +App::init(); /* * Load the configuration file which contains our DB credentials.