diff --git a/openhexa/toolbox/dhis2/dhis2.py b/openhexa/toolbox/dhis2/dhis2.py index 8759004..8edf130 100644 --- a/openhexa/toolbox/dhis2/dhis2.py +++ b/openhexa/toolbox/dhis2/dhis2.py @@ -54,7 +54,8 @@ def __init__(self, connection: DHIS2Connection, cache_dir: str = None): named after the DHIS2 instance domain. """ self.api = Api(connection) - self.cache_dir = self.setup_cache(cache_dir) + if cache_dir: + self.cache_dir = self.setup_cache(cache_dir) self.meta = Metadata(self) self.version = self.meta.system_info().get("version") self.data_value_sets = DataValueSets(self)