keep settings default if we don't set the CABOT_FROM_EMAIL address

This commit is contained in:
Mark Unsworth 2016-07-15 14:57:29 +01:00
parent b7d9c854e0
commit 1c28b15921
1 changed files with 2 additions and 1 deletions

View File

@ -16,7 +16,8 @@ ADMINS = (
MANAGERS = ADMINS
DEFAULT_FROM_EMAIL = os.environ.get('CABOT_FROM_EMAIL')
if os.environ.get('CABOT_FROM_EMAIL'):
DEFAULT_FROM_EMAIL = os.environ['CABOT_FROM_EMAIL']
DATABASES = {'default': dj_database_url.parse(os.environ["DATABASE_URL"])}