Fix a bug, where the model was overwritten.