Generally right, I still don't know, if this re-factoring comes a bit early: The re-wiring is still a bit makeshift - don't know if it scales, don't know if it actualy works with *really* many work packages. Don't know if we need more of these temporary variables - filtered_ids is never required outside of rewire_ancestors, it's only a derivative of @planning_elements, so extending the scope is at least arguable. Not sure, what will happen, if the rewiring needs to be changed again and we get more of these locally scoped variables - do we put them all into @, to make them available to all methods? I don't want to argue against the refactoring, just not sure if this is stable enough to be already refactored...