Skip to content

Commit

Permalink
chore: remove .href of pathToFileURL
Browse files Browse the repository at this point in the history
  • Loading branch information
pengbo43 committed Feb 2, 2024
1 parent 615b1f8 commit ea40418
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/req.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ async function req(name, rootFile = __filename) {
let url = createRequire(rootFile).resolve(name)

try {
return (await import(`${pathToFileURL(url).href}?t=${Date.now()}`)).default
return (await import(`${pathToFileURL(url)}?t=${Date.now()}`)).default
} catch (err) {
if (!TS_EXT_RE.test(url)) {
/* c8 ignore start */
Expand Down

0 comments on commit ea40418

Please sign in to comment.