diff options
author | Frederick Muriuki Muriithi | 2024-08-30 11:15:02 -0500 |
---|---|---|
committer | Frederick Muriuki Muriithi | 2024-08-30 11:15:02 -0500 |
commit | e55b5ff63853f1ef489c1e74b6cc0d26f9e230ce (patch) | |
tree | e4e2278457b870e5c02227b995b20770decba824 /gn_auth/auth | |
parent | c1c388ebd84035de5f7731dcdcacc42d9af0308f (diff) | |
download | gn-auth-e55b5ff63853f1ef489c1e74b6cc0d26f9e230ce.tar.gz |
If config variables are not set, return empty string.
Diffstat (limited to 'gn_auth/auth')
-rw-r--r-- | gn_auth/auth/authorisation/users/views.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gn_auth/auth/authorisation/users/views.py b/gn_auth/auth/authorisation/users/views.py index 2a6ff29..7adcd06 100644 --- a/gn_auth/auth/authorisation/users/views.py +++ b/gn_auth/auth/authorisation/users/views.py @@ -152,8 +152,8 @@ def send_verification_email( timedelta( minutes=expiration_minutes)).timestamp()) }) - send_message(smtp_user=current_app.config["SMTP_USER"], - smtp_passwd=current_app.config["SMTP_PASSWORD"], + send_message(smtp_user=current_app.config.get("SMTP_USER", ""), + smtp_passwd=current_app.config.get("SMTP_PASSWORD", ""), message=build_email_message( from_address=current_app.config["EMAIL_ADDRESS"], to_addresses=(user_address(user),), |