Completed
Pull Request — master (#290)
by Luc
05:35
created
src/StringFilter/StripLeadingSpaceStringFilter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
     public function filter($string)
12 12
     {
13 13
         if (!is_string($string)) {
14
-            throw new \InvalidArgumentException('Argument should be string, got ' . gettype($string) . ' instead.');
14
+            throw new \InvalidArgumentException('Argument should be string, got '.gettype($string).' instead.');
15 15
         }
16 16
 
17 17
         return preg_replace('/^[ \t]+/m', "", $string);
Please login to merge, or discard this patch.
src/StringFilter/StripSourceStringFilter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
     public function filter($string)
9 9
     {
10 10
         if (!is_string($string)) {
11
-            throw new \InvalidArgumentException('Argument should be string, got ' . gettype($string) . ' instead.');
11
+            throw new \InvalidArgumentException('Argument should be string, got '.gettype($string).' instead.');
12 12
         }
13 13
 
14 14
         return preg_replace('@<p class="uiv-source">.*?</p>@', '', $string);
Please login to merge, or discard this patch.
src/StringFilter/NewlineToSpaceStringFilter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
     public function filter($string)
12 12
     {
13 13
         if (!is_string($string)) {
14
-            throw new \InvalidArgumentException('Argument should be string, got ' . gettype($string) . ' instead.');
14
+            throw new \InvalidArgumentException('Argument should be string, got '.gettype($string).' instead.');
15 15
         }
16 16
 
17 17
         return preg_replace("/[\\r\\n]+/", " ", $string);
Please login to merge, or discard this patch.
src/Media/SimplePathGenerator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,6 +12,6 @@
 block discarded – undo
12 12
      */
13 13
     public function path(UUID $fileId, StringLiteral $extension)
14 14
     {
15
-        return (string)$fileId . '.' . (string)$extension;
15
+        return (string)$fileId.'.'.(string)$extension;
16 16
     }
17 17
 }
Please login to merge, or discard this patch.
src/Place/GeoCoordinatesProcessManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -129,7 +129,7 @@
 block discarded – undo
129 129
 
130 130
         // Get all physical locations from the list of addresses.
131 131
         $addresses = array_map(
132
-            function (CultureFeed_Cdb_Data_Address $address) {
132
+            function(CultureFeed_Cdb_Data_Address $address) {
133 133
                 return $address->getPhysicalAddress();
134 134
             },
135 135
             $contactInfo->getAddresses()
Please login to merge, or discard this patch.
src/Event/ReadModel/Permission/Projector.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,6 @@
 block discarded – undo
10 10
 use CultuurNet\UDB3\Event\Events\EventCreated;
11 11
 use CultuurNet\UDB3\Event\Events\EventImportedFromUDB2;
12 12
 use CultuurNet\UDB3\EventHandling\DelegateEventHandlingToSpecificMethodTrait;
13
-use CultuurNet\UDB3\Offer\Events\AbstractEvent;
14 13
 use CultuurNet\UDB3\Offer\ReadModel\Permission\PermissionRepositoryInterface;
15 14
 use ValueObjects\StringLiteral\StringLiteral;
16 15
 
Please login to merge, or discard this patch.
src/Place/ReadModel/JSONLD/PlaceLDProjector.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -184,7 +184,7 @@  discard block
 block discarded – undo
184 184
         $jsonLD->address = $placeCreated->getAddress()->toJsonLd();
185 185
 
186 186
         $calendarJsonLD = $placeCreated->getCalendar()->toJsonLd();
187
-        $jsonLD = (object) array_merge((array) $jsonLD, $calendarJsonLD);
187
+        $jsonLD = (object)array_merge((array)$jsonLD, $calendarJsonLD);
188 188
 
189 189
         $availableTo = AvailableTo::createFromCalendar($placeCreated->getCalendar());
190 190
         $jsonLD->availableTo = (string)$availableTo;
@@ -246,8 +246,8 @@  discard block
 block discarded – undo
246 246
         $jsonLD->availableTo = (string)$availableTo;
247 247
 
248 248
         // Remove old theme and event type.
249
-        $jsonLD->terms = array_filter($jsonLD->terms, function ($term) {
250
-            return $term->domain !== EventType::DOMAIN &&  $term->domain !== Theme::DOMAIN;
249
+        $jsonLD->terms = array_filter($jsonLD->terms, function($term) {
250
+            return $term->domain !== EventType::DOMAIN && $term->domain !== Theme::DOMAIN;
251 251
         });
252 252
 
253 253
         $eventType = $majorInfoUpdated->getEventType();
@@ -279,7 +279,7 @@  discard block
 block discarded – undo
279 279
         // Remove all old facilities + get numeric keys.
280 280
         $terms = array_values(array_filter(
281 281
             $terms,
282
-            function ($term) {
282
+            function($term) {
283 283
                 return $term->domain !== Facility::DOMAIN;
284 284
             }
285 285
         ));
@@ -303,7 +303,7 @@  discard block
 block discarded – undo
303 303
 
304 304
         $placeLd = $document->getBody();
305 305
 
306
-        $placeLd->geo = (object) [
306
+        $placeLd->geo = (object)[
307 307
             'latitude' => $geoCoordinatesUpdated->getCoordinates()->getLatitude()->toDouble(),
308 308
             'longitude' => $geoCoordinatesUpdated->getCoordinates()->getLongitude()->toDouble(),
309 309
         ];
Please login to merge, or discard this patch.
src/Address/CultureFeedAddressFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,12 +28,12 @@
 block discarded – undo
28 28
 
29 29
         if (count($missingFields) > 0) {
30 30
             $keys = implode(', ', $missingFields);
31
-            throw new \InvalidArgumentException('The given cdbxml address is missing a ' . $keys);
31
+            throw new \InvalidArgumentException('The given cdbxml address is missing a '.$keys);
32 32
         }
33 33
 
34 34
 
35 35
         return new Address(
36
-            new Street($cdbAddress->getStreet() . ' ' . $cdbAddress->getHouseNumber()),
36
+            new Street($cdbAddress->getStreet().' '.$cdbAddress->getHouseNumber()),
37 37
             new PostalCode($cdbAddress->getZip()),
38 38
             new Locality($cdbAddress->getCity()),
39 39
             Country::fromNative($cdbAddress->getCountry())
Please login to merge, or discard this patch.
src/Organizer/Events/WebsiteUpdated.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@
 block discarded – undo
38 38
     public function serialize()
39 39
     {
40 40
         return parent::serialize() + [
41
-                'website' => (string) $this->getWebsite()
41
+                'website' => (string)$this->getWebsite()
42 42
             ];
43 43
     }
44 44
 
Please login to merge, or discard this patch.