mirror of
https://github.com/grocy/grocy.git
synced 2026-04-04 11:56:16 +02:00
fixed undefined user id
fixed: Warning: Use of undefined constant GROCY_USER_ID - assumed 'GROCY_USER_ID' (this will throw an Error in a future version of PHP) in /www/controllers/BaseController.php on line 47
This commit is contained in:
parent
aa03ce0593
commit
bbebb1dff5
|
|
@ -44,7 +44,9 @@ class BaseController
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$usersService = new UsersService();
|
$usersService = new UsersService();
|
||||||
$container->view->set('userSettings', $usersService->GetUserSettings(GROCY_USER_ID));
|
if (defined('GROCY_USER_ID')) {
|
||||||
|
$container->view->set('userSettings', $usersService->GetUserSettings(GROCY_USER_ID));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
catch (\Exception $ex)
|
catch (\Exception $ex)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user