Commits

Anonymous committed b774409

Call get_nodes_by_type on nodelist, not template. Fixes #1.

Comments (0)

Files changed (1)

sniplates/templatetags/sniplate.py

         # Find out block
         nodes = dict(
             (n.name, n)
-            for n in tmpl.get_nodes_by_type(BlockNode)
+            for n in tmpl.nodelist.get_nodes_by_type(BlockNode)
         )
         if not name in nodes:
             raise template.TemplateSyntaxError(