nesquena/rabl — pull request #369 by sethvargo (2012-11-28 19:43:16+00:00)
Title: child fails on embedded documents (Mongoid)

This fails:

Given the following setup:

```ruby
class Parent
include Mongoid::Document
field :name

embeds_many :children
end

class Child
include Mongoid::Document
field :name

embedded_in :parent
end
```

The following code **fails** (returning null for the child `:children`):

```ruby
object @parent

child :children do
attributes :name
end
```

The following code **succeeds**, but is ugly:

```ruby
object @parent

child @parent.children => :children do
attributes :name
end
```

```text
Ruby: 1.9.3, but verified issue on 1.9.2 and 2.0.0
OS: Mac OSX 10.8.2
Rabl: 0.7.8, but also verified issue on master
Rails: 3.2.9
```