in ApiService.php in function registerRoutes(Panel $panel) there is a static function call to static::handlers(). But this makes the group() of routes in some specific cases incorrect
the array length of the groupStack should be 3 like so:
which is incorrect. because in this example the prefix should be on index 2: api/admin/{tenant}/companies and not a third index added with: api/admin/{tenant}/users/companies.
The fix should be:
remove: static::handlers(); in the ->group() function:
What happened?
in ApiService.php in function registerRoutes(Panel $panel) there is a static function call to static::handlers(). But this makes the group() of routes in some specific cases incorrect
the array length of the groupStack should be 3 like so:
but in somecases a 4th item will get appended with the next resource like so:
which is incorrect. because in this example the prefix should be on index 2:
api/admin/{tenant}/companies
and not a third index added with:api/admin/{tenant}/users/companies
.The fix should be:
remove:
static::handlers();
in the ->group() function:How to reproduce the bug
see above
Package Version
3.2
PHP Version
8.3
Laravel Version
10
Which operating systems does with happen with?
No response
Notes
No response