File configs/services.php
Why only works if i include the file, all others DI accept class call.
Thanks!
$di->set('router', function () {
$router = new Router();
include __DIR__.'/../library/System/Routes/Admin.php';
include __DIR__.'/../library/System/Routes/Frontend.php';
$router->mount(new \System\Routes\Frontend);
$router->mount(new \System\Routes\Admin);
$router->notFound(array(
"controller" => "index",
"action" => "notfound"
));
return $router;
});