-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NestApplication does not correctly implement INestApplication #4036
Comments
Please, provide a minimal repository which reproduces your issue. |
@kamilmysliwiec I do not think it is closed I am getting the same error after updating from v6.10.14 to v6.11.7 node_modules/@nestjs/core/nest-application.d.ts:44:5 - error TS2416: Property 'enableCors' in type 'NestApplication' is not assignable to the same property in base type 'INestApplication'.
Type '(options?: CorsOptions) => void' is not assignable to type '(options?: CorsOptions) => this'.
Type 'void' is not assignable to type 'this'.
44 enableCors(options?: CorsOptions): void; It was changed here #3656 |
Please, ensure that your |
That was exactly the problem... it was failing in CI when updating deps, but only because it was updating one dep at the time... sorry. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Bug Report
ERROR in C:/_myplace/gen3/platform-libs/node_modules/@nestjs/core/nest-application.d.ts(44,5):
TS2416: Property 'enableCors' in type 'NestApplication' is not assignable to the same property in base type 'INestApplication'.
Type '(options?: CorsOptions | undefined) => void' is not assignable to type '(options?: CorsOptions | undefined) => this'.
Type 'void' is not assignable to type 'this'.
It is defined as void
nest/packages/common/interfaces/nest-application.interface.ts
Line 29 in 7a65564
Implement with a return type
nest/packages/core/nest-application.ts
Line 218 in 7a65564
The only use of the function actually uses the return type
nest/packages/core/nest-application.ts
Line 106 in 7a65564
The text was updated successfully, but these errors were encountered: