From f43a6e8f8574df76d6a91b8a781099d931783bd9 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Thu, 22 Jun 2023 16:54:30 +1000 Subject: [PATCH] Tax providers --- app/Services/Tax/Providers/TaxProvider.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Services/Tax/Providers/TaxProvider.php b/app/Services/Tax/Providers/TaxProvider.php index eee35cc3e36e..980a9d292641 100644 --- a/app/Services/Tax/Providers/TaxProvider.php +++ b/app/Services/Tax/Providers/TaxProvider.php @@ -132,7 +132,7 @@ class TaxProvider 'city' => $this->client->shipping_city, 'state' => $this->client->shipping_state, 'postal_code' => $this->client->shipping_postal_code, - 'country' => $this->client?->shipping_country?->name, + 'country' => $this->client->shipping_country()->exists() ? $this->client->shipping_country->name : $this->client->country->name, ]; $taxable_address = $this->taxShippingAddress() ? $shipping_details : $billing_details;