X-Git-Url: http://git.ithinksw.org/philo.git/blobdiff_plain/1db5c3820b6bf1b1f0fc5e328fd9190ce40195a0..0a98574369a343ba6ac82aeca6250fca0383e80f:/models.py?ds=sidebyside diff --git a/models.py b/models.py index 5089508..3a06d0a 100644 --- a/models.py +++ b/models.py @@ -240,8 +240,9 @@ class Template(TreeModel): names = [] for node in nodelist: try: - if hasattr(node, 'nodelist'): - names.extend(nodelist_container_node_names(node.nodelist)) + for nodelist_name in ('nodelist', 'nodelist_loop', 'nodelist_empty', 'nodelist_true', 'nodelist_false'): + if hasattr(node, nodelist_name): + names.extend(nodelist_container_node_names(getattr(node, nodelist_name))) if isinstance(node, ContainerNode): names.append(node.name) elif isinstance(node, ExtendsNode):