Fix for nested routes validation#211
Conversation
|
@all-contributors add @vdmitriy for code and test |
|
I've put up a pull request to add @vdmitriy! 🎉 |
|
@vdmitriy your fix is available in |
|
@vdmitriy given this new change, it appears the is this correct? Assuming so, would you mind updating the signatures on the 3 For example, in public async install(app: Application | Router): Promise<void>;
public install(app: Application | Router, callback: (error: Error) => void): void;
public install(app: Application | Router, ...Note that making those changes will affect some of downstream call sites and functions and will require updating their types as well. Finally, the readme should likely indicate that either app or router can be passed to the various install methods. |
Fix for nested routes validation
Validator doesn't work if it installed for nested route instead root app, because when called from a middleware, the mount point is not included in
req.path