From 17684a14fda0bb0f066efe31273dc55f3298e7d8 Mon Sep 17 00:00:00 2001 From: Thesourtimes Date: Thu, 18 Nov 2021 22:15:05 +0300 Subject: Fix the minor issues on route --- api/src/routes/policies/instance/domains.ts | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'api/src/routes/policies/instance/domains.ts') diff --git a/api/src/routes/policies/instance/domains.ts b/api/src/routes/policies/instance/domains.ts index b68763cc..20cd07ba 100644 --- a/api/src/routes/policies/instance/domains.ts +++ b/api/src/routes/policies/instance/domains.ts @@ -3,14 +3,16 @@ import { route } from "@fosscord/api"; import { Config } from "@fosscord/util"; import { config } from "dotenv" const router = Router(); -const { cdn } = Config.get(); - -const IdentityForm = { - cdn: cdn.endpointPublic || process.env.CDN || "http://localhost:3001", -} router.get("/",route({}), async (req: Request, res: Response) => { - res.json(IdentityForm) + const { cdn, gateway } = Config.get(); + + const IdentityForm = { + cdn: cdn.endpointPublic || process.env.CDN || "http://localhost:3001", + gateway: gateway.endpointPublic || process.env.GATEWAY || "ws://localhost:3002" + }; + + res.json(IdentityForm); }); export default router; -- cgit 1.5.1