does not handle links to same nodes