From 8cf166f7eacf3e7dae22fd2f3f3b90d935043e02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Sat, 8 Oct 2022 01:10:00 +0200 Subject: [PATCH] store an end date instead of a string when person is removed from a participation --- src/Bundle/ChillPersonBundle/Entity/Person.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Bundle/ChillPersonBundle/Entity/Person.php b/src/Bundle/ChillPersonBundle/Entity/Person.php index dc59e4cec..4b494c304 100644 --- a/src/Bundle/ChillPersonBundle/Entity/Person.php +++ b/src/Bundle/ChillPersonBundle/Entity/Person.php @@ -1480,7 +1480,7 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI $participation = $this->participationsContainAccompanyingPeriod($accompanyingPeriod); if (!null === $participation) { - $participation->setEndDate(DateTimeImmutable::class); + $participation->setEndDate(new DateTime()); $this->accompanyingPeriodParticipations->removeElement($participation); } }