import logMiddleware
This commit is contained in:
parent
338213145a
commit
9d0b7317f2
1 changed files with 2 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ import * as cron from "node-cron";
|
|||
import error from "./middlewares/error";
|
||||
import { AppDataSource } from "./database/data-source";
|
||||
import { RegisterRoutes } from "./routes";
|
||||
import logMiddleware from "./middlewares/logs";
|
||||
|
||||
async function main() {
|
||||
await AppDataSource.initialize();
|
||||
|
|
@ -22,6 +23,7 @@ async function main() {
|
|||
app.use(express.json());
|
||||
app.use(express.urlencoded({ extended: true }));
|
||||
app.use("/", express.static("static"));
|
||||
app.use(logMiddleware);
|
||||
app.use("/api-docs", swaggerUi.serve, swaggerUi.setup(swaggerDocument));
|
||||
|
||||
RegisterRoutes(app);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue