v10 does not allow typing on custom getRequest
method in class with extended AuthGuard
#1413
Closed
2 tasks done
Labels
Did you read the migration guide?
Is there an existing issue that is already proposing this?
Potential Commit/PR that introduced the regression
No response
Versions
9.0.3 -> 10.0.1
Describe the regression
Previously, there was no typing for
getRequest
on theAuthGuard
class in 9.0.3. However, in 10.0.1, typing was introduced. The typing introduced conflicts with the ability to get thereq
variable from a GraphQL request when"noImplicitReturns": true
is set intsconfig.json
. The only way that I have found to get rid of the error is to introduce@ts-expect-error
or@ts-ignore
. As such, I cannot use the code used in the Passport example in the NestJS docs.Minimum reproduction code
Expected behavior
Allow the ability to type the
getRequest
method without errors thrown.Other
The error thrown with the above example is as follows:
The text was updated successfully, but these errors were encountered: