From 0f7c80e0d30f8bea8654f3c39a07c2b81e283eaa Mon Sep 17 00:00:00 2001 From: Corentin Closs Date: Fri, 27 Jan 2017 13:07:19 +0100 Subject: [PATCH] Update to work with Laravel 5.4 The Share() function doesn't work anymore in Laravel 5.4, changed the register() function to make the php artisan vendor:publish work. --- src/Artdarek/OAuth/OAuthServiceProvider.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Artdarek/OAuth/OAuthServiceProvider.php b/src/Artdarek/OAuth/OAuthServiceProvider.php index db20d52..30d2523 100644 --- a/src/Artdarek/OAuth/OAuthServiceProvider.php +++ b/src/Artdarek/OAuth/OAuthServiceProvider.php @@ -37,8 +37,7 @@ public function boot() public function register() { // Register 'oauth' - $this->app['oauth'] = $this->app->share(function ($app) - { + $this->app->singleton(OAuth::class, function ($app){ // create oAuth instance $oauth = new OAuth(); @@ -57,4 +56,4 @@ public function provides() return []; } -} \ No newline at end of file +}