Commit 61279672 authored by Dario Ernst's avatar Dario Ernst Committed by oroulet

Make recursive node deletion truly recursive

Before it only deleted the first level of nodes below the specified
list, which was not what the parameter `recursive` conveyed to the user.
parent a9dc1d36
......@@ -426,6 +426,7 @@ async def delete_nodes(server, nodes, recursive=False, delete_target_references=
async def _add_childs(nodes):
results = []
for mynode in nodes[:]:
results += await mynode.get_children()
for mynode in nodes:
results += await _add_childs(mynode.get_children())
results += [mynode]
return results
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment