@@ 501-512 (lines=12) @@ | ||
498 | ||
499 | // We found a mapping that matches the search path |
|
500 | // e.g. mapping /a/b for path /a/b |
|
501 | if ($searchPathForTest === $currentPathForTest) { |
|
502 | $foundMatchingMappings = true; |
|
503 | $result[$currentPath] = $this->resolveReferences($currentReferences, $stopOnFirst, $checkFilesystem); |
|
504 | ||
505 | // Return unless an explicit mapping order is defined |
|
506 | // In that case, the ancestors need to be searched as well |
|
507 | if ($stopOnFirst && !isset($this->json['_order'][$currentPath])) { |
|
508 | return $result; |
|
509 | } |
|
510 | ||
511 | continue; |
|
512 | } |
|
513 | ||
514 | // We found a mapping that lies within the search path |
|
515 | // e.g. mapping /a/b/c for path /a/b |
|
@@ 516-527 (lines=12) @@ | ||
513 | ||
514 | // We found a mapping that lies within the search path |
|
515 | // e.g. mapping /a/b/c for path /a/b |
|
516 | if ($includeNested && 0 === strpos($currentPathForTest, $searchPathForTest)) { |
|
517 | $foundMatchingMappings = true; |
|
518 | $result[$currentPath] = $this->resolveReferences($currentReferences, $stopOnFirst, $checkFilesystem); |
|
519 | ||
520 | // Return unless an explicit mapping order is defined |
|
521 | // In that case, the ancestors need to be searched as well |
|
522 | if ($stopOnFirst && !isset($this->json['_order'][$currentPath])) { |
|
523 | return $result; |
|
524 | } |
|
525 | ||
526 | continue; |
|
527 | } |
|
528 | ||
529 | // We found a mapping that is an ancestor of the search path |
|
530 | // e.g. mapping /a for path /a/b |