We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 54aa6ad commit 0b49a70Copy full SHA for 0b49a70
nipype/pipeline/engine/workflows.py
@@ -932,12 +932,13 @@ def _update_node_cache(self):
932
self._nested_workflows_cache.add(node)
933
934
def _has_node(self, wanted_node):
935
- if wanted_node in self._nodes_cache:
936
- return True
937
- for node in self._nested_workflows_cache:
938
- if node._has_node(wanted_node):
939
940
- return False
+ return (
+ wanted_node in self._nodes_cache or
+ any(
+ wf._has_node(wanted_node)
+ for wf in self._nested_workflows_cache
+ )
941
942
943
def _create_flat_graph(self):
944
"""Make a simple DAG where no node is a workflow."""
0 commit comments