diff --git a/http-helper/Route/Router.php b/http-helper/Route/Router.php index 11548b5e..0c61371f 100644 --- a/http-helper/Route/Router.php +++ b/http-helper/Route/Router.php @@ -74,6 +74,19 @@ class Router extends HttpService implements RouterInterface } + /** + * @return mixed + * @throws ConfigException + * @throws Exception + */ + public static function getNamespace(): string + { + $router = Kiri::app()->getRouter(); + + return Config::get('http.namespace', $router->namespace); + } + + /** * @param bool $useTree */