-
-
Couldn't load subscription status.
- Fork 29
Closed
Description
Version: 1.0.0
$schema = Expect::listOf('string')->default([
'foo',
'bar',
]);
$processor = new Processor();
$array = $processor->process($schema, [
'foo',
'bar'
]);
var_dump($array);dumps:
array(4) {
[0]=>
string(3) "foo"
[1]=>
string(3) "bar"
[2]=>
string(3) "foo"
[3]=>
string(3) "bar"
}
$schema = Expect::arrayOf('string')->default([
'foo',
'bar',
]);
$processor = new Processor();
$array = $processor->process($schema, [
'foo',
'bar'
]);
var_dump($array);dumps:
array(4) {
[0]=>
string(3) "foo"
[1]=>
string(3) "bar"
[2]=>
string(3) "foo"
[3]=>
string(3) "bar"
}
Is it the right behavior?
Metadata
Metadata
Assignees
Labels
No labels