aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorGravatar YuX <871884617@qq.com> 2022-12-10 10:17:12 +0800
committerGravatar GitHub <noreply@github.com> 2022-12-09 18:17:12 -0800
commitb400dfb386be65ca1d16ada005e75683ec48c1a5 (patch)
tree519fe0e4bfe7137671b04692b0784128a32ff41d /examples
parent88538b7c2c68fe506d0a20a8f5b78e47c6c60299 (diff)
downloadbun-b400dfb386be65ca1d16ada005e75683ec48c1a5.tar.gz
bun-b400dfb386be65ca1d16ada005e75683ec48c1a5.tar.zst
bun-b400dfb386be65ca1d16ada005e75683ec48c1a5.zip
fix path string (#1597)
Diffstat (limited to 'examples')
-rw-r--r--examples/http-file.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/http-file.ts b/examples/http-file.ts
index fdf47f949..bcd28227c 100644
--- a/examples/http-file.ts
+++ b/examples/http-file.ts
@@ -6,7 +6,7 @@ serve({
// If the URL is empty, display this file.
if (pathname === "") {
- return new Response(file(import.meta.url));
+ return new Response(file(import.meta.url.replace("file://", "")));
}
return new Response(file(pathname));