fix windows bash tool issue
This commit is contained in:
parent
14bd3b1d30
commit
e09af2cb4b
1 changed files with 1 additions and 1 deletions
|
|
@ -22,7 +22,7 @@ export const log = Log.create({ service: "bash-tool" })
|
||||||
|
|
||||||
const resolveWasm = (asset: string) => {
|
const resolveWasm = (asset: string) => {
|
||||||
if (asset.startsWith("file://")) return fileURLToPath(asset)
|
if (asset.startsWith("file://")) return fileURLToPath(asset)
|
||||||
if (asset.startsWith("/")) return asset
|
if (asset.startsWith("/") || /^[a-z]:/i.test(asset)) return asset
|
||||||
const url = new URL(asset, import.meta.url)
|
const url = new URL(asset, import.meta.url)
|
||||||
return fileURLToPath(url)
|
return fileURLToPath(url)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue