using deep copy when passing node list as param