diff --git a/metagov/metagov/core/utils.py b/metagov/metagov/core/utils.py index 6c373d63..5abacbda 100644 --- a/metagov/metagov/core/utils.py +++ b/metagov/metagov/core/utils.py @@ -145,8 +145,17 @@ def get_plugin_instance(plugin_name, community, community_platform_id=None): def get_configuration(config_name, **kwargs): + + # if multi driver functionality is on, use httpwrapper's version of get_configuration + from django.conf import settings + if hasattr(settings, "MULTI_DRIVER") and settings.MULTI_DRIVER: + from metagov.httpwrapper.utils import get_configuration as multidriver_get_configuration + return multidriver_get_configuration(config_name, **kwargs) + + # otherwise just get from environment from metagov.settings import TESTING default_val = TESTING if TESTING else None + return env(config_name, default=default_val)