copy node method improved such that it also copies collections