removed unneeded nodes.