Skip to content

Commit

Permalink
clarify in returned message if sent to only personnel only
Browse files Browse the repository at this point in the history
  • Loading branch information
rv0lt committed Oct 3, 2024
1 parent e913483 commit 7757540
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion dds_web/api/superadmin_only.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,14 @@ def post(self):
)
# Send email
utils.send_email_with_retry(msg=msg, obj=conn)

return_msg = f"MOTD '{motd_id}' has been "
if unit_personnel_only:
return_msg += "sent to unit personnel only."
else:
return_msg += "sent to all users."

return {"message": f"MOTD '{motd_id}' has been sent to the users."}
return {"message": return_msg}


class FindUser(flask_restful.Resource):
Expand Down

0 comments on commit 7757540

Please sign in to comment.