@@ -76,8 +76,8 @@ discard block |
||
76 | 76 | $this->connection->insert( |
77 | 77 | $this->rolePermissionTableName, |
78 | 78 | array( |
79 | - SchemaConfigurator::ROLE_ID_COLUMN => (string) $roleId, |
|
80 | - SchemaConfigurator::PERMISSION_COLUMN => (string) $permission, |
|
79 | + SchemaConfigurator::ROLE_ID_COLUMN => (string)$roleId, |
|
80 | + SchemaConfigurator::PERMISSION_COLUMN => (string)$permission, |
|
81 | 81 | ) |
82 | 82 | ); |
83 | 83 | } |
@@ -90,8 +90,8 @@ discard block |
||
90 | 90 | $this->connection->delete( |
91 | 91 | $this->rolePermissionTableName, |
92 | 92 | array( |
93 | - SchemaConfigurator::ROLE_ID_COLUMN => (string) $roleId, |
|
94 | - SchemaConfigurator::PERMISSION_COLUMN => (string) $permission, |
|
93 | + SchemaConfigurator::ROLE_ID_COLUMN => (string)$roleId, |
|
94 | + SchemaConfigurator::PERMISSION_COLUMN => (string)$permission, |
|
95 | 95 | ) |
96 | 96 | ); |
97 | 97 | } |
@@ -104,8 +104,8 @@ discard block |
||
104 | 104 | $this->connection->insert( |
105 | 105 | $this->userRoleTableName, |
106 | 106 | array( |
107 | - SchemaConfigurator::ROLE_ID_COLUMN => (string) $roleId, |
|
108 | - SchemaConfigurator::USER_ID_COLUMN => (string) $userId, |
|
107 | + SchemaConfigurator::ROLE_ID_COLUMN => (string)$roleId, |
|
108 | + SchemaConfigurator::USER_ID_COLUMN => (string)$userId, |
|
109 | 109 | ) |
110 | 110 | ); |
111 | 111 | } |
@@ -118,8 +118,8 @@ discard block |
||
118 | 118 | $this->connection->delete( |
119 | 119 | $this->userRoleTableName, |
120 | 120 | array( |
121 | - SchemaConfigurator::USER_ID_COLUMN => (string) $userId, |
|
122 | - SchemaConfigurator::ROLE_ID_COLUMN => (string) $roleId, |
|
121 | + SchemaConfigurator::USER_ID_COLUMN => (string)$userId, |
|
122 | + SchemaConfigurator::ROLE_ID_COLUMN => (string)$roleId, |
|
123 | 123 | ) |
124 | 124 | ); |
125 | 125 | } |
@@ -24,7 +24,7 @@ |
||
24 | 24 | } |
25 | 25 | |
26 | 26 | /** |
27 | - * @return StringLiteral |
|
27 | + * @return string |
|
28 | 28 | */ |
29 | 29 | public function getTitle() |
30 | 30 | { |
@@ -36,7 +36,7 @@ |
||
36 | 36 | public function serialize() |
37 | 37 | { |
38 | 38 | return parent::serialize() + array( |
39 | - 'title' => (string) $this->title, |
|
39 | + 'title' => (string)$this->title, |
|
40 | 40 | ); |
41 | 41 | } |
42 | 42 |
@@ -22,8 +22,8 @@ |
||
22 | 22 | */ |
23 | 23 | public function __construct(StringLiteral $userId, $command) |
24 | 24 | { |
25 | - parent::__construct('User with id: ' . $userId->toNative() . |
|
26 | - ' failed to execute command: ' . get_class($command) . |
|
25 | + parent::__construct('User with id: '.$userId->toNative(). |
|
26 | + ' failed to execute command: '.get_class($command). |
|
27 | 27 | ' because it is not authorizable.'); |
28 | 28 | |
29 | 29 | $this->userId = $userId; |
@@ -117,7 +117,7 @@ |
||
117 | 117 | */ |
118 | 118 | public function getItemId() |
119 | 119 | { |
120 | - return (string) $this->getFileId(); |
|
120 | + return (string)$this->getFileId(); |
|
121 | 121 | } |
122 | 122 | |
123 | 123 | /** |
@@ -35,7 +35,7 @@ |
||
35 | 35 | */ |
36 | 36 | public function getItemId() |
37 | 37 | { |
38 | - return (string) $this->getUuid(); |
|
38 | + return (string)$this->getUuid(); |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | /** |
@@ -23,9 +23,9 @@ |
||
23 | 23 | */ |
24 | 24 | public function byId(StringLiteral $themeId) |
25 | 25 | { |
26 | - if (!array_key_exists((string) $themeId, $this->themes)) { |
|
27 | - throw new \Exception("Unknown place theme id: " . $themeId); |
|
26 | + if (!array_key_exists((string)$themeId, $this->themes)) { |
|
27 | + throw new \Exception("Unknown place theme id: ".$themeId); |
|
28 | 28 | } |
29 | - return $this->themes[(string) $themeId]; |
|
29 | + return $this->themes[(string)$themeId]; |
|
30 | 30 | } |
31 | 31 | } |
@@ -241,7 +241,7 @@ |
||
241 | 241 | |
242 | 242 | /** |
243 | 243 | * @param PlaceDeleted $placeDeleted |
244 | - * @return null |
|
244 | + * @return JsonDocument |
|
245 | 245 | */ |
246 | 246 | protected function applyPlaceDeleted(PlaceDeleted $placeDeleted) |
247 | 247 | { |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | ); |
213 | 213 | |
214 | 214 | $calendarJsonLD = $placeCreated->getCalendar()->toJsonLd(); |
215 | - $jsonLD = (object) array_merge((array) $jsonLD, $calendarJsonLD); |
|
215 | + $jsonLD = (object)array_merge((array)$jsonLD, $calendarJsonLD); |
|
216 | 216 | |
217 | 217 | $availableTo = AvailableTo::createFromCalendar($placeCreated->getCalendar()); |
218 | 218 | $jsonLD->availableTo = (string)$availableTo; |
@@ -285,8 +285,8 @@ discard block |
||
285 | 285 | $jsonLD->availableTo = (string)$availableTo; |
286 | 286 | |
287 | 287 | // Remove old theme and event type. |
288 | - $jsonLD->terms = array_filter($jsonLD->terms, function ($term) { |
|
289 | - return $term->domain !== EventType::DOMAIN && $term->domain !== Theme::DOMAIN; |
|
288 | + $jsonLD->terms = array_filter($jsonLD->terms, function($term) { |
|
289 | + return $term->domain !== EventType::DOMAIN && $term->domain !== Theme::DOMAIN; |
|
290 | 290 | }); |
291 | 291 | |
292 | 292 | $eventType = $majorInfoUpdated->getEventType(); |
@@ -352,7 +352,7 @@ discard block |
||
352 | 352 | // @replay_i18n |
353 | 353 | // @see https://jira.uitdatabank.be/browse/III-2201 |
354 | 354 | $mainLanguageCode = $this->getMainLanguage($jsonLd)->getCode(); |
355 | - $jsonLd->address = (object) [ |
|
355 | + $jsonLd->address = (object)[ |
|
356 | 356 | $mainLanguageCode => $jsonLd->address, |
357 | 357 | ]; |
358 | 358 | } |
@@ -370,7 +370,7 @@ discard block |
||
370 | 370 | |
371 | 371 | $placeLd = $document->getBody(); |
372 | 372 | |
373 | - $placeLd->geo = (object) [ |
|
373 | + $placeLd->geo = (object)[ |
|
374 | 374 | 'latitude' => $geoCoordinatesUpdated->getCoordinates()->getLatitude()->toDouble(), |
375 | 375 | 'longitude' => $geoCoordinatesUpdated->getCoordinates()->getLongitude()->toDouble(), |
376 | 376 | ]; |
@@ -382,7 +382,7 @@ discard block |
||
382 | 382 | { |
383 | 383 | $document = $this->loadPlaceDocumentFromRepositoryById($markedAsDuplicate->getPlaceId()); |
384 | 384 | |
385 | - return $document->apply(function ($placeLd) use ($markedAsDuplicate) { |
|
385 | + return $document->apply(function($placeLd) use ($markedAsDuplicate) { |
|
386 | 386 | $placeLd->duplicateOf = $this->iriGenerator->iri($markedAsDuplicate->getDuplicateOf()); |
387 | 387 | return $placeLd; |
388 | 388 | }); |
@@ -392,7 +392,7 @@ discard block |
||
392 | 392 | { |
393 | 393 | $document = $this->loadPlaceDocumentFromRepositoryById($markedAsCanonical->getPlaceId()); |
394 | 394 | |
395 | - return $document->apply(function ($placeLd) use ($markedAsCanonical) { |
|
395 | + return $document->apply(function($placeLd) use ($markedAsCanonical) { |
|
396 | 396 | $placeLd->duplicatedBy[] = $this->iriGenerator->iri($markedAsCanonical->getDuplicatedBy()); |
397 | 397 | foreach ($markedAsCanonical->getDuplicatesOfDuplicate() as $duplicateOfDuplicate) { |
398 | 398 | $placeLd->duplicatedBy[] = $this->iriGenerator->iri($duplicateOfDuplicate); |
@@ -32,7 +32,7 @@ |
||
32 | 32 | |
33 | 33 | /** |
34 | 34 | * @param array $data |
35 | - * @return mixed The object instance |
|
35 | + * @return AbstractFacilitiesUpdated The object instance |
|
36 | 36 | */ |
37 | 37 | public static function deserialize(array $data) |
38 | 38 | { |