mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-14 21:27:20 +00:00
refactor(server): enhance the Logger usage (#9763)
This commit is contained in:
@@ -4,6 +4,7 @@ import cookieParser from 'cookie-parser';
|
||||
import graphqlUploadExpress from 'graphql-upload/graphqlUploadExpress.mjs';
|
||||
|
||||
import {
|
||||
AFFiNELogger,
|
||||
CacheInterceptor,
|
||||
CloudThrottlerGuard,
|
||||
GlobalExceptionFilter,
|
||||
@@ -20,8 +21,11 @@ export async function createApp() {
|
||||
cors: true,
|
||||
rawBody: true,
|
||||
bodyParser: true,
|
||||
bufferLogs: true,
|
||||
});
|
||||
|
||||
app.useLogger(app.get(AFFiNELogger));
|
||||
|
||||
if (AFFiNE.server.path) {
|
||||
app.setGlobalPrefix(AFFiNE.server.path);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user