From a6c0d8f063e7685535e83c7db6f3635e9f729359 Mon Sep 17 00:00:00 2001 From: Joshua T Flowers Date: Tue, 21 Jan 2020 20:57:16 +0800 Subject: [PATCH] Use existing store country if address line 1 is set (https://github.com/woocommerce/woocommerce-admin/pull/3595) --- .../client/dashboard/profile-wizard/steps/store-details.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/plugins/woocommerce-admin/client/dashboard/profile-wizard/steps/store-details.js b/plugins/woocommerce-admin/client/dashboard/profile-wizard/steps/store-details.js index cbeda40de48..531f10c5e7a 100644 --- a/plugins/woocommerce-admin/client/dashboard/profile-wizard/steps/store-details.js +++ b/plugins/woocommerce-admin/client/dashboard/profile-wizard/steps/store-details.js @@ -39,11 +39,10 @@ class StoreDetails extends Component { showUsageModal: false, }; + // Check if a store address is set so that we don't default + // to WooCommerce's default country of the UK. const countryState = - ( profileItems.hasOwnProperty( 'setup_client' ) && - null !== profileItems.setup_client && - settings.woocommerce_default_country ) || - ''; + ( settings.woocommerce_store_address && settings.woocommerce_default_country ) || ''; this.initialValues = { addressLine1: settings.woocommerce_store_address || '',