From 7e50abfdb62faf46bc4b50bba7d884333bc0ea23 Mon Sep 17 00:00:00 2001 From: Slim Amamou Date: Mon, 28 Oct 2024 11:36:14 +0100 Subject: [PATCH] fix: 500 error in prod MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit │ {"message":"Uncaught PHP Exception TypeError: \"App\\Repository\\ConfigurationRepository::getServicesParameter(): Return value must be of type bool, null returned\" at ConfigurationRepository.php line 71","context":{"exception":{"class │ │ ":"TypeError","message":"App\\Repository\\ConfigurationRepository::getServicesParameter(): Return value must be of type bool, null returned","code":0,"file":"/srv/app/src/Repository/ConfigurationRepository.php:71"}},"level":500,"level_ │ │ name":"CRITICAL","channel":"request","datetime":"2024-10-28T10:38:49.791926+01:00","extra":{}} --- src/Repository/ConfigurationRepository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Repository/ConfigurationRepository.php b/src/Repository/ConfigurationRepository.php index c2f392d..1c2ec98 100644 --- a/src/Repository/ConfigurationRepository.php +++ b/src/Repository/ConfigurationRepository.php @@ -68,6 +68,6 @@ final class ConfigurationRepository extends ServiceEntityRepository ->setMaxResults(1) ->getQuery()->getOneOrNullResult(); - return $config['configuration']['global']['globalServicesEnabled']; + return $config['configuration']['global']['globalServicesEnabled'] ?? false; } }