Skip to content

Commit

Permalink
Don't resolve a schema id against itself
Browse files Browse the repository at this point in the history
  • Loading branch information
erayd committed Oct 4, 2017
1 parent 0a6210e commit 8d7af76
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/JsonSchema/SchemaStorage.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ private function expandRefs(&$schema, $base = null)
return;
}

if (property_exists($schema, 'id') && is_string($schema->id)) {
if (property_exists($schema, 'id') && is_string($schema->id) && $base != $schema->id) {
$base = $this->uriResolver->resolve($schema->id, $base);
}

Expand Down

0 comments on commit 8d7af76

Please sign in to comment.