Skip to content

Commit

Permalink
fix: remove extra tab, fix typing
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafiot committed Mar 27, 2024
1 parent b380749 commit 27b0006
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions pylookyloo/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -461,9 +461,10 @@ def get_modules_responses(self, tree_uuid: str) -> Dict[str, Any]:
'''
r = self.session.get(urljoin(self.root_url, str(PurePosixPath('json', tree_uuid, 'modules'))))
return r.json()

def send_mail(self, tree_uuid: str, email: str = '', comment: str = None) -> True | dict[str, Any]:
to_send = {'email': email, 'comment': comment}
r = self.session.post(urljoin(self.root_url, str(PurePosixPath('json', tree_uuid, 'report'))), json=to_send)
return r.json()


def send_mail(self, tree_uuid: str, email: str = '', comment: str | None = None) -> bool | dict[str, Any]:
to_send = {'email': email}
if comment:
to_send['comment'] = comment
r = self.session.post(urljoin(self.root_url, str(PurePosixPath('json', tree_uuid, 'report'))), json=to_send)
return r.json()

0 comments on commit 27b0006

Please sign in to comment.