mirror of
https://git.sr.ht/~roxwize/mipilin
synced 2025-05-10 23:33:07 +00:00
done for today...
Signed-off-by: roxwize <rae@roxwize.xyz>
This commit is contained in:
parent
d173e6ea73
commit
453a143bfa
5 changed files with 53 additions and 7 deletions
6
main.ts
6
main.ts
|
@ -20,7 +20,7 @@ import adminRoutes from "./routes/admin.js";
|
|||
import loginRoutes from "./routes/login.js";
|
||||
import userRoutes from "./routes/users.js";
|
||||
import updateRoutes from "./routes/updates.js";
|
||||
import { createInviteCode, getMoods, render, setNonce, UserStatus } from "./routes/util.js";
|
||||
import { createInviteCode, getMoods, render, render404, setNonce, UserStatus } from "./routes/util.js";
|
||||
|
||||
const db = drizzle(process.env.DATABASE_URL!);
|
||||
|
||||
|
@ -109,6 +109,10 @@ object-src 'none'; base-uri 'none';"
|
|||
await updateRoutes(app, db);
|
||||
loginRoutes(app, db);
|
||||
|
||||
app.get("*", (req, res) => {
|
||||
render404(db, res, req);
|
||||
});
|
||||
|
||||
app.listen(1337, () => {
|
||||
console.log("Listening on http://127.0.0.1:1337/");
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue