express-openapi-validator
express-openapi-validator copied to clipboard
Custom security handlers are not run
Describe the bug When defining a custom security handler as per the documentation, it is never run.
To Reproduce
- Add a security condition to a route in the OpenAPI specification
- Define a custom handler
- Access the route without meeting the security condition (e.g. without the cookie)
Actual behavior The response is sent with the default status code and error message.
Expected behavior The response should be sent with the custom status code and error message defined in the handler.
Examples and context Here is a reproduction repository: https://github.com/stevenhair/friendly-waffle
i'm facing the same issue.
Same