Skip to content

Commit

Permalink
removed email failure exception taking an argument
Browse files Browse the repository at this point in the history
  • Loading branch information
malloc-nbytes committed Feb 11, 2025
1 parent a3e85ae commit f97bfb1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
4 changes: 2 additions & 2 deletions BackEndFlask/controller/Routes/RouteExceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ def __str__(self) -> str:
None
"""
class EmailFailureException(Exception):
def __init__(self, msg="Email failure") -> None:
self.message = msg
def __init__(self) -> None:
self.message = "Email failure"

def __str__(self) -> str:
return self.message
2 changes: 1 addition & 1 deletion BackEndFlask/models/utility.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ def send_email(address: str, subject: str, content: str):
send_message = oauth2_service.users().messages().send(userId="me", body=create_message).execute()

except Exception as e:
raise EmailFailureException(str(e))
raise EmailFailureException()


def generate_random_password(length: int):
Expand Down
3 changes: 1 addition & 2 deletions OAuth2-instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,5 +85,4 @@ what I currently use:
scp -i <path/to/pem/file> ./token.json <server@IP:/home/ubuntu>
```

SSH into the server and put the token somewhere safe *(DO NOT put it
in the repo and version control it)*.
SSH into the server and put the token in `private/`.

0 comments on commit f97bfb1

Please sign in to comment.