Fixed deletion of nodes
Added support for copying nodes