Skip to content

Commit f904974

Browse files
committed
fix local path change
1 parent 1f1b6b0 commit f904974

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/bson-bench/src/common.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ export class Package {
4646
this.library = match[1] as 'bson' | 'bson-ext';
4747

4848
this.localPath = match[2];
49-
this.computedModuleName = `${this.library}-local-${this.localPath.replaceAll('/', '_')}`;
50-
this.computedModuleName = `${this.library}-local-${this.localPath.replaceAll('\\', '_')}`;
49+
const cleanedLocalPath = this.localPath.replaceAll('/', '_').replaceAll('\\', '_');
50+
this.computedModuleName = `${this.library}-local-${cleanedLocalPath}`;
5151
} else {
5252
throw new Error('unknown package specifier');
5353
}

0 commit comments

Comments
 (0)