fixed copying of model