mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-06 10:11:38 +09:00
Fix debug disabled if first error or warning occurs before session start
This commit is contained in:
parent
b2933b7ae2
commit
c5ceafc841
1 changed files with 6 additions and 4 deletions
|
|
@ -745,12 +745,14 @@ class Debug
|
||||||
|
|
||||||
case 'admin':
|
case 'admin':
|
||||||
default:
|
default:
|
||||||
$logged_info = \Context::get('logged_info');
|
if (Session::isStarted())
|
||||||
if ($logged_info && $logged_info->is_admin === 'Y')
|
|
||||||
{
|
{
|
||||||
return self::$_enabled = true;
|
return self::$_enabled = Session::isAdmin();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
return self::$_enabled = false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue