@swell/apps-sdk 1.0.147 → 1.0.148

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -15151,7 +15151,7 @@ function ShopifyAddress(instance, address, account) {
15151
15151
  address,
15152
15152
  (address2) => address2.first_name || account?.first_name
15153
15153
  ),
15154
- id: defer(() => address.id),
15154
+ id: defer(() => address.id || address.account_address_id),
15155
15155
  last_name: deferWith(
15156
15156
  address,
15157
15157
  (address2) => address2.last_name || account?.last_name
@@ -15179,7 +15179,10 @@ function ShopifyAddress(instance, address, account) {
15179
15179
  address2.country
15180
15180
  )
15181
15181
  ),
15182
- url: deferWith(address, (address2) => `/account/addresses/${address2.id}`),
15182
+ url: deferWith(
15183
+ address,
15184
+ (address2) => `/account/addresses/${address2.id || address2.account_address_id}`
15185
+ ),
15183
15186
  zip: defer(() => address.zip)
15184
15187
  });
15185
15188
  }
@@ -15488,7 +15491,10 @@ function ShopifyCustomer(instance, account) {
15488
15491
  ),
15489
15492
  orders_count: defer(() => account.order_count),
15490
15493
  payment_methods: [],
15491
- phone: deferWith(account, (account2) => account2.phone),
15494
+ phone: deferWith(
15495
+ account,
15496
+ (account2) => account2.phone || account2.shipping?.phone || account2.billing?.phone
15497
+ ),
15492
15498
  store_credit_account: deferWith(account, (account2) => ({
15493
15499
  balance: ShopifyMoney(instance, Number(account2.balance))
15494
15500
  })),