Skip to content

Commit

Permalink
Merge pull request #71 from EasyPost/zip4-delivery-fix-abram
Browse files Browse the repository at this point in the history
Fix for sending delivery and zip4 verification in the same request
  • Loading branch information
abramclark committed Apr 16, 2018
2 parents ae6dd82 + 8ae0295 commit 3115008
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions easypost/__init__.py
Expand Up @@ -628,12 +628,10 @@ def create(cls, api_key=None, verify=None, verify_strict=None, **params):
if verify or verify_strict:
verify = verify or []
verify_strict = verify_strict or []
url += "?"

for param in verify:
url += "verify[]={0}".format(param)
for param in verify_strict:
url += "verify_strict[]={0}".format(param)
url += '?' + '&'.join(
['verify[]={0}'.format(opt) for opt in verify] +
['verify_strict[]={0}'.format(opt) for opt in verify_strict]
)

wrapped_params = {cls.class_name(): params}
response, api_key = requestor.request('post', url, wrapped_params)
Expand Down

0 comments on commit 3115008

Please sign in to comment.