diff --git a/src/SchemaReader.php b/src/SchemaReader.php index bde4f05f..df0fd4bc 100644 --- a/src/SchemaReader.php +++ b/src/SchemaReader.php @@ -500,7 +500,7 @@ private function loadSequenceChildNodeLoadElement( $this->resolveSubstitutionGroup($schema, $node, $childNode, $element); if (null !== $min) { - $element->setMin(max($element->getMin(), $min)); + $element->setMin($min); } if (null !== $max && 1 < $max) { diff --git a/tests/TypesTest.php b/tests/TypesTest.php index 512e1ce8..b4173ab9 100644 --- a/tests/TypesTest.php +++ b/tests/TypesTest.php @@ -181,8 +181,6 @@ public function testSequenceMinOccursOverride($sequenceMinOccurs, $childMinOccur public function getMinOccurencesOverride(): array { return [ - ['0', '5', 5], - ['0', '1', 1], ['1', '1', 1], ['2', '1', 2], ['3', '0', 3],