Skip to content

Commit

Permalink
Merge fix-issues-express-middlewares
Browse files Browse the repository at this point in the history
  • Loading branch information
Romain Lenzotti committed Sep 1, 2020
2 parents 0de5a4e + 0230b7e commit 447170a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
@@ -1,12 +1,14 @@
import {InjectorService} from "@tsed/di";
import {ILoggerSettings} from "../../config/interfaces/ILoggerSettings";
import {Middleware} from "../../mvc/decorators/class/middleware";
import {IMiddleware} from "../../mvc/interfaces/IMiddleware";
import {Context} from "../decorators/context";

/**
* @middleware
* @platform
*/
@Middleware()
export class PlatformLogMiddleware implements IMiddleware {
protected static DEFAULT_FIELDS = ["reqId", "method", "url", "duration"];

Expand Down
9 changes: 8 additions & 1 deletion packages/platform-express/src/index.ts
@@ -1,4 +1,10 @@
import {createExpressApplication, createHttpServer, createHttpsServer, ExpressApplication, PlatformTest} from "@tsed/common";
import {
createExpressApplication,
createHttpServer,
createHttpsServer,
ExpressApplication,
PlatformTest
} from "@tsed/common";

import {PlatformExpress} from "./components/PlatformExpress";

Expand All @@ -9,4 +15,5 @@ export * from "./services";
export * from "./utils";
export * from "./components/PlatformExpress";

export {GlobalAcceptMimesMiddleware, GlobalErrorHandlerMiddleware} from "@tsed/common";
export {createExpressApplication, createHttpServer, createHttpsServer, ExpressApplication};

0 comments on commit 447170a

Please sign in to comment.