Skip to content

Commit

Permalink
changes following review
Browse files Browse the repository at this point in the history
  • Loading branch information
8naama committed Aug 18, 2024
1 parent 799e43e commit c529979
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/apis/onepassword/OnePassword.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,7 @@ class OnePassword(ApiFetcher):

def __init__(self, **data):
# Initialize 1Password limit for number of events to return in a single request
if not data.get('onepassword_limit'):
limit = 100
else:
limit = data.pop('onepassword_limit')
limit = data.pop('onepassword_limit', 100)

# Configure the request
res_data_path = "items"
Expand Down Expand Up @@ -65,8 +62,11 @@ def _initialize_body_date(self):
new_body.update(start_time_field)
self.body = json.dumps(new_body)
except json.decoder.JSONDecodeError:
logger.error(f"Failed to update 'start_time' filter in the request body: {self.body}. Sending request with "
f"no date filter.")
logger.error(f"Failed to update 'start_time' filter in the request body: {self.body}. Sending {self.name} "
f"request with no date filter.")
except TypeError:
logger.error(f"Got unexpected request body parameter. Please make sure the {self.name} API request body is "
f"a valid json.")

def send_request(self):
"""
Expand Down
File renamed without changes.

0 comments on commit c529979

Please sign in to comment.