1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-31 20:00:37 +02:00

Defers SITEURL and dependencies until SQL loaded

This is the least intrusive solution I could come up with.

Anything else I tried to reduce technical debt would break the very
tangled dependency web, so I settled for this.

Fixes: #3033
This commit is contained in:
Deltik
2018-02-12 06:50:43 -06:00
parent de7fb1d1a0
commit d1a69b0c16
3 changed files with 199 additions and 186 deletions

6
class2.php Normal file → Executable file
View File

@@ -464,6 +464,10 @@ elseif ($merror === 'e2')
/* PHP Compatabilty should *always* be on. */
e107_require_once(e_HANDLER.'php_compatibility_handler.php');
// SITEURL constant depends on the database
// See https://github.com/e107inc/e107/issues/3033 for details.
$e107->set_urls_deferred();
//
// L: Extract core prefs from the database
//
@@ -2841,4 +2845,4 @@ function plugInstalled($plugname)
return isset($pref['plug_installed'][$plugname]);*/
}
$sql->db_Mark_Time('(After class2)');
$sql->db_Mark_Time('(After class2)');