mirror of
https://github.com/jazzband/django-dbtemplates.git
synced 2026-05-05 14:14:47 +00:00
Relaxed the cache setting handling a bit. Fixes #7.
This commit is contained in:
parent
8049569be6
commit
4507b02ed5
1 changed files with 1 additions and 4 deletions
|
|
@ -8,10 +8,7 @@ if "dbtemplates" in getattr(settings, "CACHES", {}):
|
|||
else:
|
||||
# ..or fall back to the old CACHE_BACKEND setting
|
||||
cache = getattr(settings, "DBTEMPLATES_CACHE_BACKEND", None)
|
||||
if not cache:
|
||||
raise ImproperlyConfigured("Please specify a dbtemplates "
|
||||
"cache backend in your settings.")
|
||||
elif isinstance(cache, basestring) and cache.startswith("dbtemplates."):
|
||||
if isinstance(cache, basestring) and cache.startswith("dbtemplates."):
|
||||
raise ImproperlyConfigured("Please upgrade to one of the supported "
|
||||
"backends as defined in the Django docs.")
|
||||
CACHE_BACKEND = cache
|
||||
|
|
|
|||
Loading…
Reference in a new issue