Skip to content

Commit

Permalink
Add docstring to send_email
Browse files Browse the repository at this point in the history
Add docstring to send_email to clarify what the different params are
for.

Refs EKIR-226
  • Loading branch information
natlibfi-max-grasbeck committed Jun 3, 2024
1 parent 0061e8c commit 58cc1b7
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,20 @@ def feedback(name=None):
)



def send_email(subject, body, reply_to, recipients):
'''Function that sends emails to recipients.
Args:
subject (str): the subject field of the email message to be sent
body (str): the text body of the email being sent
reply_to (str): The Reply-To header value
recipients (list): List of recipients
Returns:
bool: Return value is True if message was sent or False if not
'''

# Prevents duplicates
recipients = list(set(recipients))
message = EmailMessage()
Expand Down

0 comments on commit 58cc1b7

Please sign in to comment.