Skip to content

Commit 4d0ccbc

Browse files
authored
Legacy importer wrapper only searches for relative URLs if the URL is not canonicalized (#226)
* Legacy importer wrapper only searches for relative URLs if the URL is not canonicalized
1 parent c73d448 commit 4d0ccbc

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/src/legacy/importer.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,9 @@ export class LegacyImporterWrapper<sync extends 'sync' | 'async'>
125125

126126
this.expectingRelativeLoad = false;
127127
return null;
128-
} else {
128+
} else if (!url.startsWith('file:')) {
129+
// We'll only search for another relative import when the URL isn't
130+
// absolute.
129131
this.expectingRelativeLoad = true;
130132
}
131133

0 commit comments

Comments
 (0)