more common prep_node refactoring