Skip to content

Commit

Permalink
Accounted for another edge case around the fallback resolver. Thanks @…
Browse files Browse the repository at this point in the history
  • Loading branch information
rodinaarssen committed Dec 16, 2024
1 parent 65e6400 commit aea1af5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/org/rascalmpl/uri/URIResolverRegistry.java
Original file line number Diff line number Diff line change
Expand Up @@ -402,9 +402,11 @@ private ISourceLocation physicalLocation(ISourceLocation loc) throws IOException
ILogicalSourceLocationResolver resolver = map.get(auth);
loc = resolveAndFixOffsets(loc, resolver, map.values());
}
var fallBack = fallbackLogicalResolver;
if (fallBack != null) {
var fallbackResult = resolveAndFixOffsets(loc == null ? original : loc, fallBack, Collections.emptyList());
if (loc == null) {
loc = original;
}
if (fallbackLogicalResolver != null) {
var fallbackResult = resolveAndFixOffsets(loc == null ? original : loc, fallbackLogicalResolver, Collections.emptyList());
return fallbackResult == null ? loc : fallbackResult;
}
return loc;
Expand Down

0 comments on commit aea1af5

Please sign in to comment.