diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 539f2537fc78..4f06228f3a7e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -908,6 +908,7 @@ jobs: 'nestjs-basic', 'nestjs-distributed-tracing', 'nestjs-with-submodules', + 'nestjs-with-submodules-decorator', 'nestjs-graphql', 'node-exports-test-app', 'node-koa', diff --git a/packages/nestjs/src/decorators/with-sentry.ts b/packages/nestjs/src/decorators/with-sentry.ts index 6b02d73a94c8..cf86ea6e7cc5 100644 --- a/packages/nestjs/src/decorators/with-sentry.ts +++ b/packages/nestjs/src/decorators/with-sentry.ts @@ -12,11 +12,11 @@ export function WithSentry() { // eslint-disable-next-line @typescript-eslint/no-explicit-any descriptor.value = function (exception: unknown, host: unknown, ...args: any[]) { if (isExpectedError(exception)) { - return originalCatch.apply(this, args); + return originalCatch.apply(this, [exception, host, ...args]); } captureException(exception); - return originalCatch.apply(this, args); + return originalCatch.apply(this, [exception, host, ...args]); }; return descriptor;