From 6b220e094f215c488eb5102e25506f5b3d371245 Mon Sep 17 00:00:00 2001 From: Raphael Kabo Date: Sun, 8 Oct 2023 12:11:36 +0100 Subject: Refactor: event group form and API, extract JS --- src/app.ts | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/app.ts') diff --git a/src/app.ts b/src/app.ts index 30cf02d..c43f31d 100755 --- a/src/app.ts +++ b/src/app.ts @@ -5,6 +5,7 @@ import routes from "./routes.js"; import frontend from "./routes/frontend.js"; import activitypub from "./routes/activitypub.js"; import event from "./routes/event.js"; +import group from "./routes/group.js"; import { initEmailService } from "./lib/email.js"; @@ -33,6 +34,9 @@ const hbsInstance = hbs.create({ match[1] + (match[3] || "s") ); // Plural case: 'bagel(s)' or 'bagel' --> bagels }, + json: function (context: any) { + return JSON.stringify(context); + }, }, }); app.engine("handlebars", hbsInstance.engine); @@ -52,6 +56,7 @@ app.use(express.urlencoded({ extended: true })); app.use("/", frontend); app.use("/", activitypub); app.use("/", event); +app.use("/", group); app.use("/", routes); export default app; -- cgit v1.2.3