Permalink
Browse files

fix jinja2-templating filter

  • Loading branch information...
posativ committed Oct 31, 2013
1 parent 2c86687 commit 72b4a9628ae229b8a9ddf0be73aa03b597a8baf0
Showing with 3 additions and 3 deletions.
  1. +3 −3 acrylamid/filters/jinja2-templating.py
@@ -61,8 +61,8 @@ def system(cmd, stdin=None):
import urllib.request, urllib.parse, urllib.error
modules += [urllib.request, urllib.parse, urllib.error]
- if isinstance(env.engine, Environment):
- self.jinja2_env = env.engine.overlay(cache_size=0)
+ if isinstance(env.engine._jinja2, Environment):
+ self.jinja2_env = env.engine._jinja2.overlay(cache_size=0)
else:
self.jinja2_env = Environment(cache_size=0)
@@ -88,7 +88,7 @@ def macros(self):
post environment. Very hackish, but it should work."""
path = join(self.conf['theme'], 'macros.html')
- if not (isfile(path) and isinstance(self.env.engine, Environment)):
+ if not (isfile(path) and isinstance(self.env.engine._jinja2, Environment)):
return ''
with io.open(path, encoding='utf-8') as fp:

0 comments on commit 72b4a96

Please sign in to comment.