From 4bde29a5776012916853790275a5eab9610fc546 Mon Sep 17 00:00:00 2001 From: waiting <1661926154@qq.com> Date: Mon, 28 Oct 2024 15:32:04 +0800 Subject: [PATCH] chore(otel): clean --- packages/otel/src/middleware/trace-outer.middleware.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/otel/src/middleware/trace-outer.middleware.ts b/packages/otel/src/middleware/trace-outer.middleware.ts index 127a3270d..aace8589f 100644 --- a/packages/otel/src/middleware/trace-outer.middleware.ts +++ b/packages/otel/src/middleware/trace-outer.middleware.ts @@ -66,7 +66,6 @@ export async function middleware( const container = ctx.app.getApplicationContext() // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition const traceSvc = container.get(TraceService) ?? await container.getAsync(TraceService) - if (! traceSvc.config.enable) { return } await traceSvc.startOnRequest(ctx) ctx.res.once('finish', () => { finishCallback(ctx, traceSvc) })