started reworking the function to find and add new nodes in, I think, a more intelligent way.