Completed
Branch master (fea354)
by
unknown
02:42
created
src/Encoder/Handlers/ReplyInterpreter.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -230,7 +230,7 @@
 block discarded – undo
230 230
      * @param Frame      $current
231 231
      * @param Frame|null $previous
232 232
      *
233
-     * @return bool[]
233
+     * @return boolean[]
234 234
      */
235 235
     private function getIfTargets($rootType, Frame $current, Frame $previous = null)
236 236
     {
Please login to merge, or discard this patch.
src/Document/Document.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -264,7 +264,7 @@  discard block
 block discarded – undo
264 264
         $foundInData     = isset($this->bufferForData[$type][$idx]);
265 265
         $foundInIncluded = isset($this->bufferForIncluded[$type][$idx]);
266 266
 
267
-        $addMeta = function (array $representation, Closure $getMetaClosure) {
267
+        $addMeta = function(array $representation, Closure $getMetaClosure) {
268 268
             if (empty($representation[self::KEYWORD_RELATIONSHIPS]) === true) {
269 269
                 // if no relationships have been added remove empty placeholder
270 270
                 unset($representation[self::KEYWORD_RELATIONSHIPS]);
@@ -283,7 +283,7 @@  discard block
 block discarded – undo
283 283
             $representation = $this->bufferForData[$type][$idx];
284 284
             unset($this->bufferForData[$type][$idx]);
285 285
 
286
-            $this->data[] = $addMeta($representation, function () use ($resource) {
286
+            $this->data[] = $addMeta($representation, function() use ($resource) {
287 287
                 return $resource->getRelationshipsPrimaryMeta();
288 288
             });
289 289
         }
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
             $representation = $this->bufferForIncluded[$type][$idx];
293 293
             unset($this->bufferForIncluded[$type][$idx]);
294 294
 
295
-            $this->included[] = $addMeta($representation, function () use ($resource) {
295
+            $this->included[] = $addMeta($representation, function() use ($resource) {
296 296
                 return $resource->getRelationshipsInclusionMeta();
297 297
             });
298 298
             // remember we added (type, id) at index
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
             self::KEYWORD_LINKS    => $this->links,
317 317
             self::KEYWORD_DATA     => true, // this field wont be filtered
318 318
             self::KEYWORD_INCLUDED => empty($this->included) === true ? null : array_values($this->included),
319
-        ], function ($value) {
319
+        ], function($value) {
320 320
             return $value !== null;
321 321
         });
322 322
 
@@ -364,7 +364,7 @@  discard block
 block discarded – undo
364 364
             self::KEYWORD_ERRORS_DETAIL => $error->getDetail(),
365 365
             self::KEYWORD_ERRORS_SOURCE => $error->getSource(),
366 366
             self::KEYWORD_ERRORS_META   => $error->getMeta(),
367
-        ], function ($value) {
367
+        ], function($value) {
368 368
             return $value !== null;
369 369
         });
370 370
 
Please login to merge, or discard this patch.
src/Encoder/Parameters/ParametersAnalyzer.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
         foreach ($includePaths as $curPath) {
107 107
             if ($pathLength === 0) {
108 108
                 $relationshipName = $this->getRelationshipNameForTopResource($curPath);
109
-            } elseif (strpos($curPath, $pathBeginning . DocumentInterface::PATH_SEPARATOR) === 0) {
109
+            } elseif (strpos($curPath, $pathBeginning.DocumentInterface::PATH_SEPARATOR) === 0) {
110 110
                 $relationshipName = $this->getRelationshipNameForResource($curPath, $pathLength);
111 111
             } else {
112 112
                 $relationshipName = null;
@@ -205,8 +205,7 @@  discard block
 block discarded – undo
205 205
     {
206 206
         $nextSeparatorPos = strpos($curPath, DocumentInterface::PATH_SEPARATOR, $pathLength + 1);
207 207
         $relationshipName = $nextSeparatorPos === false ?
208
-            substr($curPath, $pathLength + 1) :
209
-            substr($curPath, $pathLength + 1, $nextSeparatorPos - $pathLength - 1);
208
+            substr($curPath, $pathLength + 1) : substr($curPath, $pathLength + 1, $nextSeparatorPos - $pathLength - 1);
210 209
 
211 210
         return $relationshipName;
212 211
     }
Please login to merge, or discard this patch.
src/Encoder/Parser/Parser.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -243,8 +243,7 @@
 block discarded – undo
243 243
     {
244 244
         ($data === null || (is_array($data) === true && empty($data) === true)) ?: Exceptions::throwLogicException();
245 245
 
246
-        $replyType = ($data === null ? ParserReplyInterface::REPLY_TYPE_NULL_RESOURCE_STARTED :
247
-            ParserReplyInterface::REPLY_TYPE_EMPTY_RESOURCE_STARTED);
246
+        $replyType = ($data === null ? ParserReplyInterface::REPLY_TYPE_NULL_RESOURCE_STARTED : ParserReplyInterface::REPLY_TYPE_EMPTY_RESOURCE_STARTED);
248 247
 
249 248
         return $this->parserFactory->createEmptyReply($replyType, $this->stack);
250 249
     }
Please login to merge, or discard this patch.
src/Encoder/Stack/StackFrame.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
             $this->path = $this->relationship->getName();
130 130
         } else {
131 131
             $this->path =
132
-                $this->previous->getPath() . DocumentInterface::PATH_SEPARATOR . $this->relationship->getName();
132
+                $this->previous->getPath().DocumentInterface::PATH_SEPARATOR.$this->relationship->getName();
133 133
         }
134 134
     }
135 135
 }
Please login to merge, or discard this patch.
src/Exceptions/ErrorCollection.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -377,7 +377,7 @@  discard block
 block discarded – undo
377 377
      */
378 378
     protected function getPathToData()
379 379
     {
380
-        return '/' . DocumentInterface::KEYWORD_DATA;
380
+        return '/'.DocumentInterface::KEYWORD_DATA;
381 381
     }
382 382
 
383 383
     /**
@@ -385,7 +385,7 @@  discard block
 block discarded – undo
385 385
      */
386 386
     protected function getPathToType()
387 387
     {
388
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_TYPE;
388
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_TYPE;
389 389
     }
390 390
 
391 391
     /**
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
      */
394 394
     protected function getPathToId()
395 395
     {
396
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_ID;
396
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_ID;
397 397
     }
398 398
 
399 399
     /**
@@ -403,7 +403,7 @@  discard block
 block discarded – undo
403 403
      */
404 404
     protected function getPathToAttribute($name)
405 405
     {
406
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_ATTRIBUTES . '/' . $name;
406
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_ATTRIBUTES.'/'.$name;
407 407
     }
408 408
 
409 409
     /**
@@ -413,7 +413,7 @@  discard block
 block discarded – undo
413 413
      */
414 414
     protected function getPathToRelationship($name)
415 415
     {
416
-        return $this->getPathToData() . '/' . DocumentInterface::KEYWORD_RELATIONSHIPS . '/' . $name;
416
+        return $this->getPathToData().'/'.DocumentInterface::KEYWORD_RELATIONSHIPS.'/'.$name;
417 417
     }
418 418
 
419 419
     /**
@@ -423,8 +423,8 @@  discard block
 block discarded – undo
423 423
      */
424 424
     protected function getPathToRelationshipType($name)
425 425
     {
426
-        return $this->getPathToRelationship($name) . '/' .
427
-            DocumentInterface::KEYWORD_DATA . '/' . DocumentInterface::KEYWORD_TYPE;
426
+        return $this->getPathToRelationship($name).'/'.
427
+            DocumentInterface::KEYWORD_DATA.'/'.DocumentInterface::KEYWORD_TYPE;
428 428
     }
429 429
 
430 430
     /**
@@ -434,7 +434,7 @@  discard block
 block discarded – undo
434 434
      */
435 435
     protected function getPathToRelationshipId($name)
436 436
     {
437
-        return $this->getPathToRelationship($name) . '/' .
438
-            DocumentInterface::KEYWORD_DATA . '/' . DocumentInterface::KEYWORD_ID;
437
+        return $this->getPathToRelationship($name).'/'.
438
+            DocumentInterface::KEYWORD_DATA.'/'.DocumentInterface::KEYWORD_ID;
439 439
     }
440 440
 }
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
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
 
73 73
         $this->type       = $type;
74 74
         $this->subType    = $subType;
75
-        $this->mediaType  = $type . '/' . $subType;
75
+        $this->mediaType  = $type.'/'.$subType;
76 76
         $this->parameters = $parameters;
77 77
     }
78 78
 
Please login to merge, or discard this patch.
src/Http/Headers/AcceptHeader.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
     public function __construct($unsortedMediaTypes)
33 33
     {
34 34
 
35
-        if (is_array($unsortedMediaTypes) ===  false) {
35
+        if (is_array($unsortedMediaTypes) === false) {
36 36
             throw new InvalidArgumentException('unsortedMediaTypes');
37 37
         }
38 38
 
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
      */
78 78
     private function getMediaTypeCompareClosure()
79 79
     {
80
-        return function (AcceptMediaTypeInterface $lhs, AcceptMediaTypeInterface $rhs) {
80
+        return function(AcceptMediaTypeInterface $lhs, AcceptMediaTypeInterface $rhs) {
81 81
             $qualityCompare = $this->compareQuality($lhs->getQuality(), $rhs->getQuality());
82 82
             if ($qualityCompare !== 0) {
83 83
                 return $qualityCompare;
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,8 @@
 block discarded – undo
44 44
     /**
45 45
      * @inheritdoc
46 46
      *
47
-     * @return AcceptHeaderInterface
47
+     * @param string $header
48
+     * @return Header
48 49
      */
49 50
     public static function parse($header, $accept = self::HEADER_ACCEPT)
50 51
     {
Please login to merge, or discard this patch.
src/Http/Responses.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -149,7 +149,7 @@  discard block
 block discarded – undo
149 149
     {
150 150
         $resSubUrl = $this->getSchemaContainer()->getSchema($resource)->getSelfSubLink($resource)->getSubHref();
151 151
         $urlPrefix = $this->getUrlPrefix();
152
-        $location  = $urlPrefix . $resSubUrl;
152
+        $location  = $urlPrefix.$resSubUrl;
153 153
 
154 154
         return $location;
155 155
     }
@@ -171,14 +171,14 @@  discard block
 block discarded – undo
171 171
         if (isset($params[MediaTypeInterface::PARAM_EXT])) {
172 172
             $ext = $params[MediaTypeInterface::PARAM_EXT];
173 173
             if (empty($ext) === false) {
174
-                $contentType .= $separator . MediaTypeInterface::PARAM_EXT . '="' . $ext . '"';
174
+                $contentType .= $separator.MediaTypeInterface::PARAM_EXT.'="'.$ext.'"';
175 175
                 $separator = ',';
176 176
             }
177 177
         }
178 178
 
179 179
         $extensions = $this->getSupportedExtensions();
180 180
         if ($extensions !== null && ($list = $extensions->getExtensions()) !== null && empty($list) === false) {
181
-            $contentType .= $separator . MediaTypeInterface::PARAM_SUPPORTED_EXT . '="' . $list . '"';
181
+            $contentType .= $separator.MediaTypeInterface::PARAM_SUPPORTED_EXT.'="'.$list.'"';
182 182
         }
183 183
 
184 184
         $headers[self::HEADER_CONTENT_TYPE] = $contentType;
Please login to merge, or discard this patch.