From 025b4b9ffdc9a59b81984999e4243133491a3cbb Mon Sep 17 00:00:00 2001 From: Lakin Wecker Date: Thu, 10 Jan 2008 11:54:44 -0700 Subject: [PATCH] Ticket #292 - [276:eed140e3c4ed] mistakenly switched the logic of when to cache and not cache, this patch fixes it and uses the more appropriate issubclass --HG-- branch : trunk --- jinja/loaders.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jinja/loaders.py b/jinja/loaders.py index 4b4937a..03a8905 100644 --- a/jinja/loaders.py +++ b/jinja/loaders.py @@ -239,7 +239,7 @@ class CachedLoaderMixin(object): try: # caching is only possible for the python translator. skip # all other translators - if isinstance(translator, PythonTranslator): + if not issubclass(translator, PythonTranslator): return super(CachedLoaderMixin, self).load( environment, name, translator) @@ -363,7 +363,7 @@ class MemcachedLoaderMixin(object): try: # caching is only possible for the python translator. skip # all other translators - if isinstance(translator, PythonTranslator): + if not issubclass(translator, PythonTranslator): return super(MemcachedLoaderMixin, self).load( environment, name, translator) tmpl = None -- 2.26.2