Completed
Branch master (ffe81d)
by Neomerx
04:33
created
src/Exceptions/ErrorCollection.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
      */
120 120
     public function add(ErrorInterface $error): self
121 121
     {
122
-        $this->items[] =$error;
122
+        $this->items[] = $error;
123 123
 
124 124
         return $this;
125 125
     }
@@ -422,7 +422,7 @@  discard block
 block discarded – undo
422 422
      */
423 423
     protected function getPathToData(): string
424 424
     {
425
-        return '/' . DocumentInterface::KEYWORD_DATA;
425
+        return '/'.DocumentInterface::KEYWORD_DATA;
426 426
     }
427 427
 
428 428
     /**
@@ -430,7 +430,7 @@  discard block
 block discarded – undo
430 430
      */
431 431
     protected function getPathToType(): string
432 432
     {
433
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_TYPE;
433
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_TYPE;
434 434
     }
435 435
 
436 436
     /**
@@ -438,7 +438,7 @@  discard block
 block discarded – undo
438 438
      */
439 439
     protected function getPathToId(): string
440 440
     {
441
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_ID;
441
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_ID;
442 442
     }
443 443
 
444 444
     /**
@@ -446,7 +446,7 @@  discard block
 block discarded – undo
446 446
      */
447 447
     protected function getPathToAttributes(): string
448 448
     {
449
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_ATTRIBUTES;
449
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_ATTRIBUTES;
450 450
     }
451 451
 
452 452
     /**
@@ -456,7 +456,7 @@  discard block
 block discarded – undo
456 456
      */
457 457
     protected function getPathToAttribute(string $name): string
458 458
     {
459
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_ATTRIBUTES . '/' . $name;
459
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_ATTRIBUTES.'/'.$name;
460 460
     }
461 461
 
462 462
     /**
@@ -464,7 +464,7 @@  discard block
 block discarded – undo
464 464
      */
465 465
     protected function getPathToRelationships(): string
466 466
     {
467
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_RELATIONSHIPS;
467
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_RELATIONSHIPS;
468 468
     }
469 469
 
470 470
     /**
@@ -474,7 +474,7 @@  discard block
 block discarded – undo
474 474
      */
475 475
     protected function getPathToRelationship(string $name): string
476 476
     {
477
-        return $this->getPathToRelationships() . '/' . $name;
477
+        return $this->getPathToRelationships().'/'.$name;
478 478
     }
479 479
 
480 480
     /**
@@ -484,8 +484,8 @@  discard block
 block discarded – undo
484 484
      */
485 485
     protected function getPathToRelationshipType(string $name): string
486 486
     {
487
-        return $this->getPathToRelationship($name) . '/' .
488
-            DocumentInterface::KEYWORD_DATA . '/' . DocumentInterface::KEYWORD_TYPE;
487
+        return $this->getPathToRelationship($name).'/'.
488
+            DocumentInterface::KEYWORD_DATA.'/'.DocumentInterface::KEYWORD_TYPE;
489 489
     }
490 490
 
491 491
     /**
@@ -495,7 +495,7 @@  discard block
 block discarded – undo
495 495
      */
496 496
     protected function getPathToRelationshipId(string $name): string
497 497
     {
498
-        return $this->getPathToRelationship($name) . '/' .
499
-            DocumentInterface::KEYWORD_DATA . '/' . DocumentInterface::KEYWORD_ID;
498
+        return $this->getPathToRelationship($name).'/'.
499
+            DocumentInterface::KEYWORD_DATA.'/'.DocumentInterface::KEYWORD_ID;
500 500
     }
501 501
 }
Please login to merge, or discard this patch.
src/Encoder/Encoder.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -255,8 +255,7 @@
 block discarded – undo
255 255
     protected function encodeToJson(array $document): string
256 256
     {
257 257
         return $this->getEncoderOptions() === null ?
258
-            json_encode($document) :
259
-            json_encode($document, $this->getEncoderOptions()->getOptions(), $this->getEncoderOptions()->getDepth());
258
+            json_encode($document) : json_encode($document, $this->getEncoderOptions()->getOptions(), $this->getEncoderOptions()->getDepth());
260 259
     }
261 260
 
262 261
     /**
Please login to merge, or discard this patch.
src/Schema/BaseSchema.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -78,16 +78,16 @@  discard block
 block discarded – undo
78 78
     {
79 79
         assert(
80 80
             is_string($this->getResourceType()) === true && empty($this->getResourceType()) === false,
81
-            'Resource type is not set for Schema \'' . static::class . '\'.'
81
+            'Resource type is not set for Schema \''.static::class.'\'.'
82 82
         );
83 83
 
84 84
         if ($this->selfSubUrl === null) {
85
-            $this->selfSubUrl = '/' . $this->getResourceType();
85
+            $this->selfSubUrl = '/'.$this->getResourceType();
86 86
         } else {
87 87
             assert(
88 88
                 is_string($this->selfSubUrl) === true && empty($this->selfSubUrl) === false &&
89 89
                 $this->selfSubUrl[0] === '/' && $this->selfSubUrl[strlen($this->selfSubUrl) - 1] != '/',
90
-                '\'Self\' sub-url set incorrectly for Schema \'' . static::class . '\'.'
90
+                '\'Self\' sub-url set incorrectly for Schema \''.static::class.'\'.'
91 91
             );
92 92
         }
93 93
 
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
      */
108 108
     public function getSelfSubUrl($resource = null): string
109 109
     {
110
-        return $resource === null ? $this->selfSubUrl : $this->selfSubUrl . '/' . $this->getId($resource);
110
+        return $resource === null ? $this->selfSubUrl : $this->selfSubUrl.'/'.$this->getId($resource);
111 111
     }
112 112
 
113 113
     /**
@@ -272,7 +272,7 @@  discard block
 block discarded – undo
272 272
      */
273 273
     protected function getRelationshipSelfUrl($resource, $name)
274 274
     {
275
-        $url = $this->getSelfSubUrl($resource) . '/' . DocumentInterface::KEYWORD_RELATIONSHIPS . '/' . $name;
275
+        $url = $this->getSelfSubUrl($resource).'/'.DocumentInterface::KEYWORD_RELATIONSHIPS.'/'.$name;
276 276
 
277 277
         return $url;
278 278
     }
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
      */
286 286
     protected function getRelationshipRelatedUrl($resource, $name)
287 287
     {
288
-        $url = $this->getSelfSubUrl($resource) . '/' . $name;
288
+        $url = $this->getSelfSubUrl($resource).'/'.$name;
289 289
 
290 290
         return $url;
291 291
     }
Please login to merge, or discard this patch.
src/Document/Link.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@
 block discarded – undo
92 92
      */
93 93
     public function getHref(string $prefix = null): string
94 94
     {
95
-        return $this->isTreatAsHref() === true ? $this->getSubHref() : $prefix . $this->getSubHref();
95
+        return $this->isTreatAsHref() === true ? $this->getSubHref() : $prefix.$this->getSubHref();
96 96
     }
97 97
 
98 98
     /**
Please login to merge, or discard this patch.
src/Http/Query/BaseQueryParser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@
 block discarded – undo
66 66
     public function getIncludes(): iterable
67 67
     {
68 68
         if (array_key_exists(static::PARAM_INCLUDE, $this->getParameters()) === true) {
69
-            $splitByDot = function (string $path): iterable {
69
+            $splitByDot = function(string $path): iterable {
70 70
                 foreach ($this->splitStringAndCheckNoEmpties(static::PARAM_INCLUDE, $path, '.') as $link) {
71 71
                     yield $link;
72 72
                 }
Please login to merge, or discard this patch.
src/Http/Headers/AcceptMediaType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@
 block discarded – undo
87 87
      */
88 88
     public static function getCompare(): Closure
89 89
     {
90
-        return function (AcceptMediaTypeInterface $lhs, AcceptMediaTypeInterface $rhs) {
90
+        return function(AcceptMediaTypeInterface $lhs, AcceptMediaTypeInterface $rhs) {
91 91
             $qualityCompare = self::compareQuality($lhs->getQuality(), $rhs->getQuality());
92 92
             if ($qualityCompare !== 0) {
93 93
                 return $qualityCompare;
Please login to merge, or discard this patch.
src/Http/Headers/MediaType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@
 block discarded – undo
97 97
     public function getMediaType(): string
98 98
     {
99 99
         if ($this->mediaType === null) {
100
-            $this->mediaType = $this->getType() . '/' . $this->getSubType();
100
+            $this->mediaType = $this->getType().'/'.$this->getSubType();
101 101
         }
102 102
 
103 103
         return $this->mediaType;
Please login to merge, or discard this patch.
src/Http/BaseResponses.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -168,7 +168,7 @@
 block discarded – undo
168 168
     {
169 169
         $resSubUrl = $this->getSchemaContainer()->getSchema($resource)->getSelfSubLink($resource)->getSubHref();
170 170
         $urlPrefix = $this->getUrlPrefix();
171
-        $location  = $urlPrefix . $resSubUrl;
171
+        $location  = $urlPrefix.$resSubUrl;
172 172
 
173 173
         return $location;
174 174
     }
Please login to merge, or discard this patch.