Skip to content

Commit fe7d6be

Browse files
Correção do ArraySerializer.php
1 parent 569f7bd commit fe7d6be

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
}
1717
],
1818
"require": {
19-
"php": ">=7.0",
19+
"php": "^7.1",
2020
"cakephp/cakephp": "^3.6",
2121
"league/fractal": ">=0.13.0"
2222
},

src/Serializer/ArraySerializer.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ class ArraySerializer extends Serializer
99
/**
1010
* Serialize a collection.
1111
*
12-
* @param string $resourceKey resource key
13-
* @param array $data data
12+
* @param string|null $resourceKey resource key
13+
* @param array $data data
1414
*
1515
* @return array
1616
*/
17-
public function collection($resourceKey, array $data)
17+
public function collection(?string $resourceKey, array $data): array
1818
{
1919
return $data;
2020
}

0 commit comments

Comments
 (0)