diff options
-rw-r--r-- | examples/hono/package.json | 2 | ||||
-rw-r--r-- | examples/hono/src/index.ts | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/examples/hono/package.json b/examples/hono/package.json index 46e977334..5ac888fb7 100644 --- a/examples/hono/package.json +++ b/examples/hono/package.json @@ -1,5 +1,5 @@ { - "version": "1.0.0", + "version": "1.0.1", "name": "@bun-examples/hono", "main": "src/index.js", "devDependencies": { diff --git a/examples/hono/src/index.ts b/examples/hono/src/index.ts index 2bc0be21c..145bd5db0 100644 --- a/examples/hono/src/index.ts +++ b/examples/hono/src/index.ts @@ -2,7 +2,7 @@ import { Hono } from "hono"; const app = new Hono(); -const port = process.env.PORT || 3000; +const port = parseInt(process.env.PORT) || 3000; const home = app.get("/", (c) => { return c.json({ message: "Hello World!" }); @@ -11,6 +11,6 @@ const home = app.get("/", (c) => { console.log(`Running at http://localhost:${port}`); export default { - port: process.env.PORT || 3000, + port, fetch: home.fetch, }; |