Closed
Description
Hi,
I encounter a bug with the merge function when the schema use a list of string.
Here is an example :
`
$schema = Expect::structure([
'paths' => Expect::arrayOf('string')->default(['path_1']),
]);
$data = ['paths' => ['path_1']];
`
after the processSchema() i got the following result :
['path_1', 'path_1']
but i expect the values to be merged, and only have ['path_1']
as a result. This wrong behavior is when the array has numeric keys. If a use an associative array (ex : ['default' => 'path_1']) the merge work fine and i got only on element for the result.
Keep up the good work, this library is amazing :)
Metadata
Metadata
Assignees
Labels
No labels