- 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)))