Kamil
Kamil
> LGTM if it works (did not test that yet), but please add some unit tests 😉 that would be icing on the cake 👍🏻 [https://github.com/bramus/router/pull/158/commits/75d5c6e13c836b3a961194ac6f48a794280639b0](https://github.com/bramus/router/pull/158/commits/75d5c6e13c836b3a961194ac6f48a794280639b0)
Sorry, I forgot one small detail, but very important ``` $router->mount('/api/v1', function () use ($router) { $router->setNamespace('Api\v1'); // !!! $router->get('/', function() { echo 'API version 1 overview'; }); $router->get('add', function()...
> You're right. The current project structure does not allow that because `setNamespace` [defines just a class-variable](https://github.com/bramus/router/blob/master/src/Bramus/Router/Router.php#L250). To fix that, you need to [move `getNamespace`](https://github.com/bramus/router/blob/master/src/Bramus/Router/Router.php#L467). Please consider making a pull...