From f4be149bf33be2a24bf5353b6e2349bd27385229 Mon Sep 17 00:00:00 2001 From: Pig Fang Date: Tue, 20 Aug 2019 10:12:35 +0800 Subject: [PATCH] Tweak PluginServiceProvider --- app/Providers/PluginServiceProvider.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/Providers/PluginServiceProvider.php b/app/Providers/PluginServiceProvider.php index 3dbaea47..71b890f7 100644 --- a/app/Providers/PluginServiceProvider.php +++ b/app/Providers/PluginServiceProvider.php @@ -9,7 +9,10 @@ class PluginServiceProvider extends ServiceProvider { public function register() { - $this->app->singleton('plugins', PluginManager::class); + $this->app->singleton(PluginManager::class); + $this->app->singleton('plugins', function ($app) { + return $app->make(PluginManager::class); + }); } public function boot(PluginManager $plugins)