-
-
Notifications
You must be signed in to change notification settings - Fork 8k
Closed
Copy link
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into
Description
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
I've created a reproduction example with the readme detailing the issue here: https://github.com/gentunian/nestjs-router-module-bug-children-path-empty-string
TL&DR
The RouterModule
won't set the MODULE_PATH
metadata correctly to the module being passed when the path
is an empty string. Instead, it will set the metadata to an object, that is the { path: '', module: <module> }
object.
Minimum reproduction code
https://github.com/gentunian/nestjs-router-module-bug-children-path-empty-string
Steps to reproduce
No response
Expected behavior
It's expected that RouterModule
would set the appropriate MODULE_PATH
metadata to the module. In this case, the MODULE_PATH
would be the flattened one.
Package
- I don't know. Or some 3rd-party package
-
@nestjs/common
-
@nestjs/core
-
@nestjs/microservices
-
@nestjs/platform-express
-
@nestjs/platform-fastify
-
@nestjs/platform-socket.io
-
@nestjs/platform-ws
-
@nestjs/testing
-
@nestjs/websockets
- Other (see below)
Other package
No response
NestJS version
v11.0.1
Packages versions
Node.js version
v22.15.0
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response
Metadata
Metadata
Assignees
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into