From 6f006f38a484bbdf2449cda1cfbc96c3de6ee49e Mon Sep 17 00:00:00 2001 From: CrescentLeaf Date: Sun, 21 Sep 2025 02:13:55 +0800 Subject: [PATCH] fix: app.use -> get --- server/main.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/main.ts b/server/main.ts index db14cc0..120cbe8 100644 --- a/server/main.ts +++ b/server/main.ts @@ -15,7 +15,7 @@ import path from "node:path" const app = express() app.use('/', express.static(config.data_path + '/page_compiled')) -app.use('/uploaded_files/:hash', (req, res) => { +app.get('/uploaded_files/:hash', (req, res) => { const hash = req.params.hash as string if (hash == null) { res.sendStatus(404) @@ -39,7 +39,7 @@ const httpServer: HttpServerLike = ( http.createServer(app) ) const io = new SocketIo.Server(httpServer, { - + maxHttpBufferSize: 1e9, }) ApiManager.initServer(httpServer, io)