Skip to content

Commit

Permalink
fix: dots in paths causing source map path matching issue (#1983)
Browse files Browse the repository at this point in the history
Fixes #1944
  • Loading branch information
connor4312 committed Apr 1, 2024
1 parent 91a3e54 commit 185bcca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/targets/sourcePathResolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export abstract class SourcePathResolverBase<T extends ISourcePathResolverOption
const prefix = location.startsWith('!') ? '!' : '';

// replace extensions with anything, to allow both .js and .map
let suffix = location.slice(prefix.length).replace(/(?<!\.)\.[^.]+$/, '.*');
let suffix = location.slice(prefix.length).replace(/(?<!\.)\.[^./\\]+$/, '.*');
if (!isAbsolute(suffix)) {
return forceForwardSlashes(location);
}
Expand Down

0 comments on commit 185bcca

Please sign in to comment.