lib/relaxo/model/properties/composite.rb in relaxo-model-0.4.0 vs lib/relaxo/model/properties/composite.rb in relaxo-model-0.4.1
- old
+ new
@@ -98,10 +98,10 @@
end
class HasMany < HasOne
def convert_to_primative(value)
value.each do |document|
- document.save unless value.id
+ document.save unless document.saved?
end
value.collect{|document| document.id}
end