diff --git a/src/LocalizationServiceProvider.php b/src/LocalizationServiceProvider.php index 2f1cfba..a8d81f3 100644 --- a/src/LocalizationServiceProvider.php +++ b/src/LocalizationServiceProvider.php @@ -30,18 +30,16 @@ public function register() $packageConfigFile, 'localization' ); - $this->app['localization.localize'] = $this->app->share( - function () { + $this->app->singleton('localization.localize', function () { return new Localize(); } ); - $this->app['localization.router'] = $this->app->share( - function () { + $this->app->singleton('localization.router', function () { return new Router(); } ); } -} \ No newline at end of file +}