Skip to content

Commit

Permalink
Normalize windows path for findAsset
Browse files Browse the repository at this point in the history
  • Loading branch information
etrepum committed May 31, 2024
1 parent 7289332 commit db1eedd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/lexical-playground/__tests__/utils/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function findAsset(pattern) {
const prefix = 'packages/lexical-playground/build';
const resolvedPattern = `${prefix}/assets/${pattern}`;
for (const fn of glob.sync(resolvedPattern, {windowsPathsNoEscape: true})) {
return fn.slice(prefix.length);
return fn.replace('\\', '/').slice(prefix.length);
}
throw new Error(`Missing asset at ${resolvedPattern}`);
}
Expand Down

0 comments on commit db1eedd

Please sign in to comment.