aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2023-12-20 11:58:33 +0100
committerMario <mario@mariovavti.com>2023-12-20 11:58:33 +0100
commit6f852814fd5ba6dab0e56e6d73666d438e6d0c09 (patch)
treed69a0ac807db498e8ff46a0137ce1d1db7e81e9e /Zotlabs/Lib
parentb15e521b0eebba7001dc87be0bc9fe0cee19aa23 (diff)
downloadvolse-hubzilla-6f852814fd5ba6dab0e56e6d73666d438e6d0c09.tar.gz
volse-hubzilla-6f852814fd5ba6dab0e56e6d73666d438e6d0c09.tar.bz2
volse-hubzilla-6f852814fd5ba6dab0e56e6d73666d438e6d0c09.zip
move App::$install check to Config::Load() as suggested by Harald
Diffstat (limited to 'Zotlabs/Lib')
-rw-r--r--Zotlabs/Lib/Config.php9
1 files changed, 2 insertions, 7 deletions
diff --git a/Zotlabs/Lib/Config.php b/Zotlabs/Lib/Config.php
index b1754df09..5e735be34 100644
--- a/Zotlabs/Lib/Config.php
+++ b/Zotlabs/Lib/Config.php
@@ -36,7 +36,7 @@ class Config {
if (! array_key_exists('config_loaded', App::$config[$family])) {
$r = q("SELECT * FROM config WHERE cat = '%s'", dbesc($family));
- if ($r === false) {
+ if ($r === false && !App::$install) {
sleep(3);
$recursionCounter ++;
if ($recursionCounter > 10) {
@@ -44,7 +44,7 @@ class Config {
}
self::Load($family, $recursionCounter);
}
- else {
+ elseif (is_array($r)) {
foreach ($r as $rr) {
$k = $rr['k'];
App::$config[$family][$k] = $rr['v'];
@@ -122,11 +122,6 @@ class Config {
*/
public static function Get($family, $key, $default = false) {
- if (App::$install) {
- // The DB is not initalized yet
- return false;
- }
-
if ((! array_key_exists($family, App::$config)) || (! array_key_exists('config_loaded', App::$config[$family]))) {
self::Load($family);
}