fixes deleteNode