Skip to content

Commit 52b5d86

Browse files
authored
Merge pull request #2192 from microsoft/connor4312/smpo-node
fix: apply sourceMapPathOverrides to Node, too
2 parents 4490d96 + f4c67ac commit 52b5d86

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/targets/node/nodeSourcePathResolver.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,11 @@ export class NodeSourcePathResolver extends SourcePathResolverBase<IOptions> {
7373
public async urlToAbsolutePath({ url, map }: IUrlResolution): Promise<string | undefined> {
7474
url = this.normalizeSourceMapUrl(url);
7575

76+
// It's possible the source might be using the `sourceURL`, so apply
77+
// any source map overrides now (fixes vscode#204784) and before file
78+
// URIs (vscode-dwarf-debugging-ext#7)
79+
url = this.sourceMapOverrides.apply(url);
80+
7681
// Allow debugging of externally loaded Node internals
7782
// [ by building Node with ./configure --node-builtin-modules-path $(pwd) ]
7883
if (url.startsWith(localNodeInternalsPrefix) && this.options.basePath) {

0 commit comments

Comments
 (0)