mirror of
https://github.com/flarum/core.git
synced 2025-10-18 10:16:09 +02:00
Shorten registration of routes
This commit is contained in:
@@ -46,11 +46,9 @@ class ForumServiceProvider extends AbstractServiceProvider
|
||||
});
|
||||
|
||||
$this->app->singleton('flarum.forum.routes', function () {
|
||||
return new RouteCollection;
|
||||
});
|
||||
|
||||
$this->app->afterResolving('flarum.forum.routes', function (RouteCollection $routes) {
|
||||
$routes = new RouteCollection;
|
||||
$this->populateRoutes($routes);
|
||||
return $routes;
|
||||
});
|
||||
|
||||
$this->app->singleton('flarum.forum.middleware', function (Application $app) {
|
||||
|
Reference in New Issue
Block a user