/** * Register the service provider. * * @return void */ public function register() { parent::register(); $this->app->singleton('api.router.adapter', function ($app) { return new LumenAdapter($app, new StdRouteParser(), new GcbDataGenerator(), 'FastRoute\\Dispatcher\\GroupCountBased'); }); }
/** * Register the service provider. * * @return void */ public function register() { parent::register(); $reflection = new ReflectionClass($this->app); $this->app->instance('app.middleware', $this->gatherAppMiddleware($reflection)); $this->addRequestMiddlewareToBeginning($reflection); $this->app->singleton('api.router.adapter', function ($app) { return new LumenAdapter($app, new StdRouteParser(), new GcbDataGenerator(), 'FastRoute\\Dispatcher\\GroupCountBased'); }); }
/** * Register the service provider. * * @return void */ public function register() { parent::register(); $this->registerRouterAdapter(); }