Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
StyleCIBot committed Feb 8, 2024
1 parent b41613f commit 1648672
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/Taxes/Providers/ModuleServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,6 @@ public function register(): void
{
parent::register();

$this->app->singleton(TaxEngineManager::class, fn($app) => new TaxEngineManager($app));
$this->app->singleton(TaxEngineManager::class, fn ($app) => new TaxEngineManager($app));
}
}
10 changes: 5 additions & 5 deletions src/Taxes/Resolver/TaxEngineManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ public function __construct(
) {
}

public function __call(string $method, array $arguments)
{
return $this->driver()->$method(...$arguments);
}

public function driver(?string $name = null): TaxRateResolver
{
$name = $name ?: $this->getDefaultDriver();
Expand All @@ -66,11 +71,6 @@ public function findTaxRate(Taxable $taxable, ?Address $billingAddress = null, ?
return $this->driver()->findTaxRate($taxable, $billingAddress, $shippingAddress);
}

public function __call(string $method, array $arguments)
{
return $this->driver()->$method(...$arguments);
}

protected function getDefaultDriver(): string
{
return $this->app['config']['vanilo.taxes.engine.driver'] ?? self::NULL_DRIVER;
Expand Down

0 comments on commit 1648672

Please sign in to comment.