diff --git a/lib/acts_as_versioned.rb b/lib/acts_as_versioned.rb index 135c079..6356dd2 100644 --- a/lib/acts_as_versioned.rb +++ b/lib/acts_as_versioned.rb @@ -332,7 +332,7 @@ def altered? # Clones a model. Used when saving a new version or reverting a model's version. def clone_versioned_model(orig_model, new_model) self.class.versioned_columns.each do |col| - new_model.send("#{col.name}=", orig_model.send(col.name)) if orig_model.has_attribute?(col.name) + new_model[col.name] = orig_model.send(col.name) if orig_model.has_attribute?(col.name) end if orig_model.is_a?(self.class.versioned_class)