fixed deepCopy