Fixed path bug, removed unneeded inclusion of deleted nodes, tidy up