I'm having hard time to configure nested groups in CI 4. I'm trying to configure the access to routes passing thru a group of filters to authenticate and validate the data that i'm using in the controller.
Here's a example of the configuration:
$routes->group('api/', ['filter' => 'jwt'], function ($routes) {
$routes->group('', ['filter' => 'scopefilter:test'], function ($routes) {
$routes->post('test', 'Api\Test::index');
});
});
In this case, the only filter that worked is the scopefilter. The jwt is invisible. The expecting behavior was that the request should pass thru jwt filter and than the scopefilter.
Has anyone already solved this?