adding add_edge fxn to node