Skip to content

Commit

Permalink
fix(settings): relax environment check for dev/test
Browse files Browse the repository at this point in the history
  • Loading branch information
thekaveman committed Jan 28, 2025
1 parent ea944da commit 4f5fb26
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ def RUNTIME_ENVIRONMENT():
# usage of django.conf.settings.ALLOWED_HOSTS here (rather than the module variable directly)
# is to ensure dynamic calculation, e.g. for unit tests and elsewhere this setting is needed
env = RUNTIME_ENVS.LOCAL
if "dev.disasterrecovery.ca.gov" in settings.ALLOWED_HOSTS:
if "dev" in settings.ALLOWED_HOSTS:
env = RUNTIME_ENVS.DEV
elif "test.disasterrecovery.ca.gov" in settings.ALLOWED_HOSTS:
elif "test" in settings.ALLOWED_HOSTS:
env = RUNTIME_ENVS.TEST
elif "disasterrecovery.ca.gov" in settings.ALLOWED_HOSTS:
env = RUNTIME_ENVS.PROD
Expand Down

0 comments on commit 4f5fb26

Please sign in to comment.