python-terminusgps 36.1.3__py3-none-any.whl → 36.2.0__py3-none-any.whl

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-terminusgps
3
- Version: 36.1.3
3
+ Version: 36.2.0
4
4
  Summary: Provides abstractions/utilities for working with Wialon API, Authorize.NET API, AWS API, and more.
5
5
  Project-URL: Documentation, https://docs.terminusgps.com
6
6
  Project-URL: Repository, https://github.com/terminusgps/python-terminusgps
@@ -7,7 +7,7 @@ terminusgps/authorizenet/utils.py,sha256=FrKqXWrplcgiET1rDTmUaqmN_ze7j93jWgfFeJR
7
7
  terminusgps/authorizenet/profiles/__init__.py,sha256=IG4XCEEYtHKqXOatlZlob6J3ukAgF7cFR-RXxOSMS1c,161
8
8
  terminusgps/authorizenet/profiles/addresses.py,sha256=5GudJStBa4P0Hd7G_hRFH2C-WpICAH_k3MT9YJkicKw,6305
9
9
  terminusgps/authorizenet/profiles/base.py,sha256=Pu1NGrvC5Ox2W1oZuVcPqUw3aUoSK191Evexw1U6_3k,3940
10
- terminusgps/authorizenet/profiles/customers.py,sha256=lLzQPJByu_oEck8u3h4vzoV_uVOKKeLr6qhFAV5uQ_E,12793
10
+ terminusgps/authorizenet/profiles/customers.py,sha256=CAinLbFOixvhcUWCYu1pbZDElhyvtX93oBQkoeQaixM,12723
11
11
  terminusgps/authorizenet/profiles/payments.py,sha256=nhudGuJ6RzmK0MrhDVuYL2BxvyzKNpliBIfIpFU5Y-4,11038
12
12
  terminusgps/authorizenet/profiles/subscriptions.py,sha256=m_jb9GqeD1tLmeqSnaGwJrzPcQOulEkF8K1wCaqKR24,7924
13
13
  terminusgps/authorizenet/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -52,7 +52,7 @@ terminusgps/wialon/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZ
52
52
  terminusgps/wialon/tests/test_items.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
53
53
  terminusgps/wialon/tests/test_session.py,sha256=9mBlYchMo9NeqRIZsmxYzrM1zBHorqu4ooxqSNppLpI,1336
54
54
  terminusgps/wialon/tests/test_utils.py,sha256=SK4PxJQGECFnzx_EQeRAQfsQ5_3FLaVcis2W9u_ibuI,1730
55
- python_terminusgps-36.1.3.dist-info/METADATA,sha256=3DwmldpvpHiF5EBQbdnTXHXqHqOrOqV2y7ELuX_PKTU,1616
56
- python_terminusgps-36.1.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
57
- python_terminusgps-36.1.3.dist-info/licenses/COPYING,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
58
- python_terminusgps-36.1.3.dist-info/RECORD,,
55
+ python_terminusgps-36.2.0.dist-info/METADATA,sha256=JEx5k-8-huypQryiLolU4amgRqUztsNP-RsnYiFZtwM,1616
56
+ python_terminusgps-36.2.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
57
+ python_terminusgps-36.2.0.dist-info/licenses/COPYING,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
58
+ python_terminusgps-36.2.0.dist-info/RECORD,,
@@ -16,7 +16,7 @@ class CustomerProfile(AuthorizenetProfileBase):
16
16
  desc: str | None = None,
17
17
  ) -> None:
18
18
  """
19
- Sets :py:attr:`merchant_id`, :py:attr:`email` and :py:attr:`desc`.
19
+ Sets :py:attr:`merchantCustomerId`, :py:attr:`email` and :py:attr:`desc`.
20
20
 
21
21
  :returns: Nothing.
22
22
  :rtype: :py:obj:`None`
@@ -169,12 +169,12 @@ class CustomerProfile(AuthorizenetProfileBase):
169
169
 
170
170
  """
171
171
  response = self._authorizenet_get_customer_profile()
172
- if response is not None:
172
+ if response is not None and hasattr(response.profile, "paymentProfiles"):
173
173
  return [
174
174
  int(p.customerPaymentProfileId)
175
175
  for p in response.profile.paymentProfiles
176
- if hasattr(response.profile, "paymentProfiles")
177
176
  ]
177
+ return []
178
178
 
179
179
  def get_address_profile_ids(self) -> list[int]:
180
180
  """
@@ -185,12 +185,9 @@ class CustomerProfile(AuthorizenetProfileBase):
185
185
 
186
186
  """
187
187
  response = self._authorizenet_get_customer_profile()
188
- if response is not None:
189
- return [
190
- int(p.customerAddressId)
191
- for p in response.profile.shipToList
192
- if hasattr(response.profile, "shipToList")
193
- ]
188
+ if response is not None and hasattr(response.profile, "shipToList"):
189
+ return [int(p.customerAddressId) for p in response.profile.shipToList]
190
+ return []
194
191
 
195
192
  def _generate_customer_profile_ex_type(
196
193
  self,
@@ -256,12 +253,10 @@ class CustomerProfile(AuthorizenetProfileBase):
256
253
 
257
254
  if self.id:
258
255
  request.customerProfileId = self.id
259
- elif self.merchantCustomerId:
256
+ if self.merchantCustomerId:
260
257
  request.merchantCustomerId = self.merchantCustomerId
261
- elif self.email:
258
+ if self.email:
262
259
  request.email = self.email
263
- else:
264
- return
265
260
 
266
261
  controller = apicontrollers.getCustomerProfileController(request)
267
262
  return self.execute_controller(controller)