From c82b71695d16b0ef19d5e976ea7ca47c62ef3345 Mon Sep 17 00:00:00 2001 From: Madeline <46743919+MaddyUnderStars@users.noreply.github.com> Date: Thu, 28 Sep 2023 16:10:57 +0000 Subject: send Follow request to guild when remote invite code used --- src/bundle/Server.ts | 11 +++++++++-- src/bundle/index.ts | 5 +++-- 2 files changed, 12 insertions(+), 4 deletions(-) (limited to 'src/bundle') diff --git a/src/bundle/Server.ts b/src/bundle/Server.ts index 72d38603..d76875e5 100644 --- a/src/bundle/Server.ts +++ b/src/bundle/Server.ts @@ -23,7 +23,12 @@ import { FederationServer } from "@spacebar/ap"; import * as Api from "@spacebar/api"; import { CDNServer } from "@spacebar/cdn"; import * as Gateway from "@spacebar/gateway"; -import { Config, Sentry, initDatabase } from "@spacebar/util"; +import { + Config, + Sentry, + initDatabase, + setupMorganLogging, +} from "@spacebar/util"; import express from "express"; import http from "http"; import { bold, green } from "picocolors"; @@ -35,9 +40,9 @@ const production = process.env.NODE_ENV == "development" ? false : true; server.on("request", app); const api = new Api.SpacebarServer({ server, port, production, app }); +const federation = new FederationServer({ server, port, production, app }); const cdn = new CDNServer({ server, port, production, app }); const gateway = new Gateway.Server({ server, port, production }); -const federation = new FederationServer({ server, port, production, app }); process.on("SIGTERM", async () => { console.log("Shutting down due to SIGTERM"); @@ -53,6 +58,8 @@ async function main() { await Config.init(); await Sentry.init(app); + setupMorganLogging(app); + await new Promise((resolve) => server.listen({ port }, () => resolve(undefined)), ); diff --git a/src/bundle/index.ts b/src/bundle/index.ts index c6af4f00..8b1c9429 100644 --- a/src/bundle/index.ts +++ b/src/bundle/index.ts @@ -16,7 +16,8 @@ along with this program. If not, see . */ +export * from "@spacebar/ap"; export * from "@spacebar/api"; -export * from "@spacebar/util"; -export * from "@spacebar/gateway"; export * from "@spacebar/cdn"; +export * from "@spacebar/gateway"; +export * from "@spacebar/util"; -- cgit 1.5.1