Skip to content

Commit

Permalink
Update changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
durran committed Feb 11, 2012
1 parent 6c9ded7 commit f94256d
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions CHANGELOG.md
Expand Up @@ -24,6 +24,29 @@ For instructions on upgrading to newer versions, visit

* \#1680 Polymorphic relations now use `*_type` keys in lookup queries.

* \#1677 Support for parent separable polymorphic relations to the same
parent class is now available. This only works if set from the parent
side in order to know which relation the children belong to.
(Douwe Maan)

class Face
include Mongoid::Document
has_one :left_eye, class_name: "Eye", as: :visible
has_one :right_eye, class_name: "Eye", as: :visible
end

class Eye
include Mongoid::Document
belongs_to :visible, polymorphic: true
end

face = Face.new
right_eye = Eye.new
left_eye = Eye.new
face.right_eye = right_eye
face.left_eye = left_eye
right_eye.face = face # Will raise an error.

* \#1650 Objects that respond to \#to_criteria can now be merged into
existing criteria objects.

Expand Down

0 comments on commit f94256d

Please sign in to comment.