Completed
Pull Request — master (#1036)
by Hector
05:37 queued 02:33
created
src/JsonApi/Serializer/ItemNormalizer.php 2 patches
Doc Comments   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -262,7 +262,6 @@  discard block
 block discarded – undo
262 262
     /**
263 263
      * Populates links and relationships keys.
264 264
      *
265
-     * @param array       $data
266 265
      * @param object      $object
267 266
      * @param string|null $format
268 267
      * @param array       $context
@@ -362,7 +361,7 @@  discard block
 block discarded – undo
362 361
      * @param string|null $format
363 362
      * @param array       $context
364 363
      *
365
-     * @return bool|string
364
+     * @return string|false
366 365
      */
367 366
     private function getCacheKey(string $format = null, array $context)
368 367
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -236,8 +236,7 @@
 block discarded – undo
236 236
                     (
237 237
                         null !== $className
238 238
                             && $this->resourceClassResolver->isResourceClass($className)
239
-                                ? $this->resourceMetadataFactory->create($className)->getShortName() :
240
-                                ''
239
+                                ? $this->resourceMetadataFactory->create($className)->getShortName() : ''
241 240
                     );
242 241
             }
243 242
 
Please login to merge, or discard this patch.
src/JsonApi/Serializer/CollectionNormalizer.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -178,8 +178,7 @@
 block discarded – undo
178 178
 
179 179
         if (is_array($object) || $object instanceof \Countable) {
180 180
             $data['meta']['totalItems'] = $object instanceof PaginatorInterface ?
181
-                (int) $object->getTotalItems() :
182
-                count($object);
181
+                (int) $object->getTotalItems() : count($object);
183 182
         }
184 183
 
185 184
         if ($isPaginator) {
Please login to merge, or discard this patch.
src/Serializer/NameConverter/CamelCaseToDashedCaseNameConverter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@
 block discarded – undo
71 71
      */
72 72
     public function denormalize($propertyName)
73 73
     {
74
-        $camelCasedName = preg_replace_callback('/(^|-|\.)+(.)/', function ($match) {
74
+        $camelCasedName = preg_replace_callback('/(^|-|\.)+(.)/', function($match) {
75 75
             return ('.' === $match[1] ? '-' : '').strtoupper($match[2]);
76 76
         }, $propertyName);
77 77
 
Please login to merge, or discard this patch.