@@ -366,8 +366,8 @@ discard block |
||
366 | 366 | // Set the new calendar. |
367 | 367 | $calendarJsonLD = $eventCopied->getCalendar()->toJsonLd(); |
368 | 368 | |
369 | - $eventJsonLD = (object) array_merge( |
|
370 | - (array) $eventJsonLD, |
|
369 | + $eventJsonLD = (object)array_merge( |
|
370 | + (array)$eventJsonLD, |
|
371 | 371 | $calendarJsonLD |
372 | 372 | ); |
373 | 373 | |
@@ -387,7 +387,7 @@ discard block |
||
387 | 387 | |
388 | 388 | // Set available to and from. |
389 | 389 | $availableTo = AvailableTo::createFromCalendar($eventCopied->getCalendar()); |
390 | - $eventJsonLD->availableTo = (string) $availableTo; |
|
390 | + $eventJsonLD->availableTo = (string)$availableTo; |
|
391 | 391 | unset($eventJsonLD->availableFrom); |
392 | 392 | |
393 | 393 | $newDocument = new JsonDocument($eventCopied->getItemId()); |
@@ -433,8 +433,8 @@ discard block |
||
433 | 433 | $jsonLD->availableTo = (string)$availableTo; |
434 | 434 | |
435 | 435 | // Remove old theme and event type. |
436 | - $jsonLD->terms = array_filter($jsonLD->terms, function ($term) { |
|
437 | - return $term->domain !== EventType::DOMAIN && $term->domain !== Theme::DOMAIN; |
|
436 | + $jsonLD->terms = array_filter($jsonLD->terms, function($term) { |
|
437 | + return $term->domain !== EventType::DOMAIN && $term->domain !== Theme::DOMAIN; |
|
438 | 438 | }); |
439 | 439 | $jsonLD->terms = array_values($jsonLD->terms); |
440 | 440 | |
@@ -462,7 +462,7 @@ discard block |
||
462 | 462 | |
463 | 463 | $jsonLD->location = [ |
464 | 464 | '@type' => 'Place', |
465 | - ] + (array) $this->placeJSONLD($locationUpdated->getLocationId()->toNative()); |
|
465 | + ] + (array)$this->placeJSONLD($locationUpdated->getLocationId()->toNative()); |
|
466 | 466 | |
467 | 467 | return $document->withBody($jsonLD); |
468 | 468 | } |
@@ -477,7 +477,7 @@ discard block |
||
477 | 477 | |
478 | 478 | $eventLd = $document->getBody(); |
479 | 479 | |
480 | - $eventLd->location->geo = (object) [ |
|
480 | + $eventLd->location->geo = (object)[ |
|
481 | 481 | 'latitude' => $geoCoordinatesUpdated->getCoordinates()->getLatitude()->toDouble(), |
482 | 482 | 'longitude' => $geoCoordinatesUpdated->getCoordinates()->getLongitude()->toDouble(), |
483 | 483 | ]; |
@@ -531,7 +531,7 @@ discard block |
||
531 | 531 | { |
532 | 532 | $eventSlug = $this->slugger->slug($name); |
533 | 533 | return array( |
534 | - 'http://www.uitinvlaanderen.be/agenda/e/' . $eventSlug . '/' . $eventId, |
|
534 | + 'http://www.uitinvlaanderen.be/agenda/e/'.$eventSlug.'/'.$eventId, |
|
535 | 535 | ); |
536 | 536 | } |
537 | 537 |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | |
81 | 81 | $offerRequest = new Request( |
82 | 82 | 'GET', |
83 | - (string) $offerQuery, |
|
83 | + (string)$offerQuery, |
|
84 | 84 | $headers |
85 | 85 | ); |
86 | 86 | |
@@ -89,14 +89,14 @@ discard block |
||
89 | 89 | ->getBody() |
90 | 90 | ->getContents(); |
91 | 91 | |
92 | - $this->logger->debug('Send SAPI3 request with the following parameters: ' . json_encode($queryParameters)); |
|
93 | - $this->logger->debug('Response data: ' . $searchResponseData); |
|
92 | + $this->logger->debug('Send SAPI3 request with the following parameters: '.json_encode($queryParameters)); |
|
93 | + $this->logger->debug('Response data: '.$searchResponseData); |
|
94 | 94 | |
95 | 95 | $searchResponseData = json_decode($searchResponseData); |
96 | 96 | |
97 | 97 | $offerIds = array_reduce( |
98 | 98 | $searchResponseData->{'member'}, |
99 | - function (OfferIdentifierCollection $offerIds, $item) { |
|
99 | + function(OfferIdentifierCollection $offerIds, $item) { |
|
100 | 100 | return $offerIds->with( |
101 | 101 | $this->offerIdentifier->fromIri(Url::fromNative($item->{'@id'})) |
102 | 102 | ); |
@@ -26,14 +26,14 @@ discard block |
||
26 | 26 | if ($cdbCalendar instanceof \CultureFeed_Cdb_Data_Calendar_PeriodList) { |
27 | 27 | /** @var \CultureFeed_Cdb_Data_Calendar_Period $period */ |
28 | 28 | $period = $cdbCalendar->current(); |
29 | - $startDateString = $period->getDateFrom() . 'T00:00:00'; |
|
29 | + $startDateString = $period->getDateFrom().'T00:00:00'; |
|
30 | 30 | } elseif ($cdbCalendar instanceof \CultureFeed_Cdb_Data_Calendar_TimestampList) { |
31 | 31 | /** @var \CultureFeed_Cdb_Data_Calendar_Timestamp $timestamp */ |
32 | 32 | $timestamp = $cdbCalendar->current(); |
33 | 33 | if ($timestamp->getStartTime()) { |
34 | - $startDateString = $timestamp->getDate() . 'T' . substr($timestamp->getStartTime(), 0, 5) . ':00'; |
|
34 | + $startDateString = $timestamp->getDate().'T'.substr($timestamp->getStartTime(), 0, 5).':00'; |
|
35 | 35 | } else { |
36 | - $startDateString = $timestamp->getDate() . 'T00:00:00'; |
|
36 | + $startDateString = $timestamp->getDate().'T00:00:00'; |
|
37 | 37 | } |
38 | 38 | } |
39 | 39 | $startDate = !empty($startDateString) ? DateTimeFactory::dateTimeFromDateString($startDateString) : null; |
@@ -46,17 +46,17 @@ discard block |
||
46 | 46 | if ($cdbCalendar instanceof \CultureFeed_Cdb_Data_Calendar_PeriodList) { |
47 | 47 | /** @var \CultureFeed_Cdb_Data_Calendar_Period $period */ |
48 | 48 | $period = $cdbCalendar->current(); |
49 | - $endDateString = $period->getDateTo() . 'T00:00:00'; |
|
49 | + $endDateString = $period->getDateTo().'T00:00:00'; |
|
50 | 50 | } elseif ($cdbCalendar instanceof \CultureFeed_Cdb_Data_Calendar_TimestampList) { |
51 | 51 | $firstTimestamp = $cdbCalendar->current(); |
52 | 52 | /** @var \CultureFeed_Cdb_Data_Calendar_Timestamp $timestamp */ |
53 | 53 | $cdbCalendarAsArray = iterator_to_array($cdbCalendar); |
54 | 54 | $timestamp = $this->getLastTimestamp($cdbCalendarAsArray, $firstTimestamp); |
55 | 55 | if ($timestamp->getEndTime()) { |
56 | - $endDateString = $timestamp->getDate() . 'T' . $timestamp->getEndTime(); |
|
56 | + $endDateString = $timestamp->getDate().'T'.$timestamp->getEndTime(); |
|
57 | 57 | } else { |
58 | 58 | $endTime = $timestamp->getStartTime() ? $timestamp->getStartTime() : '00:00:00'; |
59 | - $endDateString = $timestamp->getDate() . 'T' . $endTime; |
|
59 | + $endDateString = $timestamp->getDate().'T'.$endTime; |
|
60 | 60 | } |
61 | 61 | } |
62 | 62 | $endDate = !empty($endDateString) ? DateTimeFactory::dateTimeFromDateString($endDateString) : null; |
@@ -74,12 +74,12 @@ discard block |
||
74 | 74 | $cdbCalendar->next(); |
75 | 75 | |
76 | 76 | $startTime = $timestamp->getStartTime() ? $timestamp->getStartTime() : '00:00:00'; |
77 | - $startDateString = $timestamp->getDate() . 'T' . $startTime; |
|
77 | + $startDateString = $timestamp->getDate().'T'.$startTime; |
|
78 | 78 | |
79 | 79 | if ($timestamp->getEndTime()) { |
80 | - $endDateString = $timestamp->getDate() . 'T' . $timestamp->getEndTime(); |
|
80 | + $endDateString = $timestamp->getDate().'T'.$timestamp->getEndTime(); |
|
81 | 81 | } else { |
82 | - $endDateString = $timestamp->getDate() . 'T' . $startTime; |
|
82 | + $endDateString = $timestamp->getDate().'T'.$startTime; |
|
83 | 83 | } |
84 | 84 | |
85 | 85 | $timestamp = $this->createTimestamp( |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | } |
97 | 97 | |
98 | 98 | $periods = array_map( |
99 | - function (array $periodParts) { |
|
99 | + function(array $periodParts) { |
|
100 | 100 | $firstPart = array_shift($periodParts); |
101 | 101 | $lastPart = array_pop($periodParts); |
102 | 102 | return new Timestamp( |