feat: update server login feature (#3004)

Co-authored-by: LongYinan <lynweklm@gmail.com>
This commit is contained in:
Alex Yang
2023-07-05 11:13:20 +08:00
committed by GitHub
parent 9cd1f013f8
commit 3084c427f1
7 changed files with 127 additions and 305 deletions
+3
View File
@@ -1,6 +1,7 @@
/// <reference types="./global.d.ts" />
import { NestFactory } from '@nestjs/core';
import type { NestExpressApplication } from '@nestjs/platform-express';
import cookieParser from 'cookie-parser';
import { static as staticMiddleware } from 'express';
// @ts-expect-error graphql-upload is not typed
import graphqlUploadExpress from 'graphql-upload/graphqlUploadExpress.mjs';
@@ -27,6 +28,8 @@ app.use(
})
);
app.use(cookieParser());
const config = app.get(Config);
const host = config.host ?? 'localhost';