Fix api listen url print

This commit is contained in:
Zoe Roux 2025-05-04 22:52:17 +02:00
parent 7413284581
commit f200e63cb2
No known key found for this signature in database
2 changed files with 4 additions and 4 deletions

View File

@ -55,7 +55,7 @@ export const base = new Elysia({ name: "base" })
.as("plugin");
export const prefix = process.env.KYOO_PREFIX ?? "";
export const app = new Elysia({ prefix })
export const handlers = new Elysia({ prefix })
.use(base)
.use(auth)
.guard(

View File

@ -1,6 +1,6 @@
import { swagger } from "@elysiajs/swagger";
import Elysia from "elysia";
import { app } from "./base";
import { handlers } from "./base";
import { processImages } from "./controllers/seed/images";
import { migrate } from "./db";
import { comment } from "./utils";
@ -10,7 +10,7 @@ await migrate();
// run image processor task in background
processImages();
new Elysia()
const app = new Elysia()
.use(
swagger({
scalarConfig: {
@ -83,7 +83,7 @@ new Elysia()
},
}),
)
.use(app)
.use(handlers)
.listen(3567);
console.log(`Api running at ${app.server?.hostname}:${app.server?.port}`);