Skip to content

Commit

Permalink
Фикс сервис-провайдера Laravel
Browse files Browse the repository at this point in the history
  • Loading branch information
jhaoda committed Oct 17, 2019
1 parent e9411df commit bb4a5af
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/LaravelServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,23 @@ class LaravelServiceProvider extends ServiceProvider

public function register()
{
$this->app->singleton(SingleAccessClient::class, static function (Container $app) {
$this->app->singleton(SingleAccessClient::class, function (Container $app) {
$config = $app['config']['services.russianpost.tracking'];

return $this->setLoggerToClient(
new SingleAccessClient($config['login'], $config['password'])
);
});

$this->app->singleton(PacketAccessClient::class, static function (Container $app) {
$this->app->singleton(PacketAccessClient::class, function (Container $app) {
$config = $app['config']['services.russianpost.tracking'];

return $this->setLoggerToClient(
new PacketAccessClient($config['login'], $config['password'])
);
});

$this->app->singleton(DispatchingClient::class, static function (Container $app) {
$this->app->singleton(DispatchingClient::class, function (Container $app) {
$config = $app['config']['services.russianpost.dispatching'];

$client = new DispatchingClient(
Expand Down

0 comments on commit bb4a5af

Please sign in to comment.