Skip to content

Commit 4ac1103

Browse files
committed
fix(command): call toString after pathToFileURL
1 parent 8e38be9 commit 4ac1103

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

bin/command.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,9 @@ async function parseMiddleware( config, options ) {
253253
const middleware = await Promise.all(
254254
[ ...( config.middleware ?? [] ), ...( options.middleware ?? [] ) ].map(
255255
async( mw ) => {
256-
const module = await import( pathToFileURL( resolve( process.cwd(), mw ) ) );
256+
const module = await import(
257+
pathToFileURL( resolve( process.cwd(), mw ) ).toString()
258+
);
257259
return module.default;
258260
}
259261
)

0 commit comments

Comments
 (0)