From ad36478d1fcf19d5bc76602592455c07bc5aa477 Mon Sep 17 00:00:00 2001 From: Raphael Odini Date: Sat, 5 Aug 2023 11:29:24 +0200 Subject: [PATCH] Hotfix error in MembershipService. ref #918 --- src/AppBundle/Service/MembershipService.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/AppBundle/Service/MembershipService.php b/src/AppBundle/Service/MembershipService.php index 1ed92325c..4b020c302 100644 --- a/src/AppBundle/Service/MembershipService.php +++ b/src/AppBundle/Service/MembershipService.php @@ -20,6 +20,7 @@ class MembershipService protected $registration_duration; protected $registration_every_civil_year; protected $cycle_type; + protected $use_fly_and_fixed; public function __construct(ContainerInterface $container, EntityManagerInterface $em) { @@ -27,6 +28,7 @@ public function __construct(ContainerInterface $container, EntityManagerInterfac $this->registration_duration = $container->getParameter('registration_duration'); $this->registration_every_civil_year = $container->getParameter('registration_every_civil_year'); $this->cycle_type = $container->getParameter('cycle_type'); + $this->use_fly_and_fixed = $container->getParameter('use_fly_and_fixed'); } /** @@ -199,7 +201,7 @@ public function hasWarningStatus(Membership $member): bool $member->isCurrentlyExemptedFromShifts() || !$this->isUptodate($member); - if ($this->container->getParameter('use_fly_and_fixed')) { + if ($this->use_fly_and_fixed) { $hasWarningStatus = $hasWarningStatus || $member->isFlying(); }