Merge branch 'hotfix/regression-fix' into develop

This commit is contained in:
Björn Fromme
2021-06-26 15:27:06 +02:00
@@ -72,16 +72,13 @@ class GroupsSwissService implements SingletonInterface, LoggerAwareInterface
{
$range = Period::after(new \DateTime('now'), '1 year');
$result = $this->hotelRepository->findByIdentifier($hotelUid);
$hotel = $this->hotelRepository->findByIdentifier($hotelUid);
if (null === $result) {
if (null === $hotel) {
$this->logger->error(sprintf('Hotel with uid %d not found', $hotelUid));
return false;
}
/** @var Hotel $hotel */
$hotel = $result->getFirst();
try {
$events = $this->contingentRepository->getEvents(
\DateTime::createFromImmutable($range->getStartDate()),