diff piecrust/templating/jinja/extensions.py @ 858:58e28ba02fb7

refactor: Fix a few more pieces of code using the old APIs.
author Ludovic Chabant <ludovic@chabant.com>
date Thu, 08 Jun 2017 08:50:33 -0700
parents 448710d84121
children cedefb806bfd
line wrap: on
line diff
--- a/piecrust/templating/jinja/extensions.py	Thu Jun 08 08:49:33 2017 -0700
+++ b/piecrust/templating/jinja/extensions.py	Thu Jun 08 08:50:33 2017 -0700
@@ -128,9 +128,8 @@
     def _cache_support(self, name, caller):
         key = self.environment.piecrust_cache_prefix + name
 
-        exc_stack = self.environment.app.env.exec_info_stack
-        render_ctx = exc_stack.current_page_info.render_ctx
-        rdr_pass = render_ctx.current_pass_info
+        rcs = self.environment.app.env.render_ctx_stack
+        rdr_pass = rcs.current_ctx.current_pass_info
 
         # try to load the block from the cache
         # if there is no fragment in the cache, render it and store