From d565abc3aa012729d26150d8c087801c7db473f8 Mon Sep 17 00:00:00 2001 From: Bernd Bestel Date: Tue, 16 Jun 2026 20:24:26 +0200 Subject: [PATCH] Fixed 404 error handling --- controllers/ExceptionController.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/controllers/ExceptionController.php b/controllers/ExceptionController.php index 2b95e42e..9c3f6b1c 100644 --- a/controllers/ExceptionController.php +++ b/controllers/ExceptionController.php @@ -25,6 +25,11 @@ class ExceptionController extends BaseApiController public function __invoke(ServerRequestInterface $request, Throwable $exception, bool $displayErrorDetails, bool $logErrors, bool $logErrorDetails, ?LoggerInterface $logger = null) { + if (!defined('GROCY_LOCALE')) + { + define('GROCY_LOCALE', GROCY_DEFAULT_LOCALE); + } + $response = $this->ResponseFactory->createResponse(); $isApiRoute = string_starts_with($request->getUri()->getPath(), '/api/');