Skip to content

Commit 2ba8f95

Browse files
committed
delimiter defaulted to a value before loop
1 parent 7099ef0 commit 2ba8f95

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/JsonSchema/Constraints/ObjectConstraint.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ public function validatePatternProperties($element, $path, $patternProperties)
4545
$try = array('/','#','+','~','%');
4646
$matches = array();
4747
foreach ($patternProperties as $pregex => $schema) {
48+
$delimiter = '/';
4849
// Choose delimiter. Necessary for patterns like ^/ , otherwise you get error
4950
foreach ($try as $delimiter) {
5051
if (strpos($pregex, $delimiter) === false) { // safe to use

0 commit comments

Comments
 (0)