mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-27 01:39:22 +02:00
Fix Twig error on create account
This commit is contained in:
parent
5ccfcd541e
commit
7e13b62b8f
@ -31,9 +31,6 @@ if($config['gzip_output'] && isset($_SERVER['HTTP_ACCEPT_ENCODING']) && strpos($
|
|||||||
require_once SYSTEM . 'libs/cache.php';
|
require_once SYSTEM . 'libs/cache.php';
|
||||||
$cache = Cache::getInstance();
|
$cache = Cache::getInstance();
|
||||||
|
|
||||||
// twig
|
|
||||||
require_once SYSTEM . 'twig.php';
|
|
||||||
|
|
||||||
// trim values we receive
|
// trim values we receive
|
||||||
if(isset($_POST))
|
if(isset($_POST))
|
||||||
{
|
{
|
||||||
@ -126,6 +123,9 @@ require_once SYSTEM . 'libs/pot/OTS.php';
|
|||||||
$ots = POT::getInstance();
|
$ots = POT::getInstance();
|
||||||
require_once SYSTEM . 'database.php';
|
require_once SYSTEM . 'database.php';
|
||||||
|
|
||||||
|
// twig
|
||||||
|
require_once SYSTEM . 'twig.php';
|
||||||
|
|
||||||
define('USE_ACCOUNT_NAME', $db->hasColumn('accounts', 'name'));
|
define('USE_ACCOUNT_NAME', $db->hasColumn('accounts', 'name'));
|
||||||
// load vocation names
|
// load vocation names
|
||||||
$tmp = '';
|
$tmp = '';
|
||||||
|
@ -16,6 +16,9 @@ $twig = new Twig_Environment($twig_loader, array(
|
|||||||
|
|
||||||
$twig_loader->addPath(PLUGINS);
|
$twig_loader->addPath(PLUGINS);
|
||||||
|
|
||||||
|
$twig->addGlobal('logged', false);
|
||||||
|
$twig->addGlobal('account_logged', new OTS_Account());
|
||||||
|
|
||||||
if($dev_mode) {
|
if($dev_mode) {
|
||||||
$twig->addExtension(new Twig_DebugExtension());
|
$twig->addExtension(new Twig_DebugExtension());
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user