From d17b9a2f2733f5ddcf8fa61f3877fc3fcb3ef8fa Mon Sep 17 00:00:00 2001 From: pictuga Date: Thu, 23 Dec 2021 12:02:24 +0100 Subject: [PATCH] Fix typo in DISKCACHE_DIR var name --- README.md | 2 +- morss/caching.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 24fc010..0f827af 100644 --- a/README.md +++ b/README.md @@ -481,7 +481,7 @@ environment variables: `MYSQL_USER`, `MYSQL_PWD`, `MYSQL_DB`, `MYSQL_HOST` - `CACHE=redis`: Redis cache. Connection can be defined with the following environment variables: `REDIS_HOST`, `REDIS_PORT`, `REDIS_DB`, `REDIS_PWD` - `CACHE=diskcache`: disk-based cache. Target directory canbe defined with -`DISKCAHE_DIR`. +`DISKCACHE_DIR`. To limit the size of the cache: diff --git a/morss/caching.py b/morss/caching.py index 3d1ecec..cc867f6 100644 --- a/morss/caching.py +++ b/morss/caching.py @@ -205,7 +205,7 @@ if 'CACHE' in os.environ: elif os.environ['CACHE'] == 'diskcache': default_cache = DiskCacheHandler( - directory = os.getenv('DISKCAHE_DIR', '/tmp/morss-diskcache'), + directory = os.getenv('DISKCACHE_DIR', '/tmp/morss-diskcache'), size_limit = CACHE_SIZE # in Bytes )