Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
chenjiahan committed Sep 17, 2024
1 parent 1ec1c1e commit a43ce92
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/core/src/plugins/rsdoctor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@ export const pluginRsdoctor = (): RsbuildPlugin => ({

let module: RsdoctorExports;
try {
module = await import(pathToFileURL(packagePath).href);
const modulePath = pathToFileURL(packagePath).href;
module = await import(modulePath);
} catch (err) {
logger.error(
`\`process.env.RSDOCTOR\` enabled, but failed to load ${color.bold(color.yellow(packageName))} module.`,
Expand Down

0 comments on commit a43ce92

Please sign in to comment.