diff --git a/src/Providers/ClientServiceProvider.php b/src/Providers/ClientServiceProvider.php index 29a2d35..8dd7b0f 100644 --- a/src/Providers/ClientServiceProvider.php +++ b/src/Providers/ClientServiceProvider.php @@ -21,8 +21,8 @@ class ClientServiceProvider extends ServiceProvider $config = config('rpc.client'); $logger = new Logger('rpc-client-logger'); $logger->pushHandler(new StreamHandler($this->app->storagePath()."/logs/rpc_client_".date("Ymd").".log")); - $this->app->singleton('rpc', function () use ($config) { - return new Client($config); + $this->app->singleton('rpc', function () use ($config, $logger) { + return new Client($config, $logger); }); foreach ($config as $k => $item) {