Skip to content

Commit 3c44f16

Browse files
committed
Additionally filter out non nil empty values for country code
1 parent 80eab35 commit 3c44f16

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

WooCommerce/Classes/ViewRelated/Orders/Order Details/Shipping Labels/WooShipping Create Shipping Labels/WooShipping Customs/WooShippingCustomsItemViewModel.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ private extension WooShippingCustomsItemViewModel {
103103
func combineToPreselectCountry() {
104104
$originCountryCode
105105
.compactMap { $0 }
106+
.filter { !$0.isEmpty }
106107
.first() /// Make sure to only handle the initial value
107108
.combineLatest($countries)
108109
.map { code, countries in

0 commit comments

Comments
 (0)