mongoid/mongoid — pull request #1888 by dakatsuka (2012-04-03 12:28:30+00:00)
Title: Improved performance of Mongoid::Relations::Referenced::In

I've improved performance of Mongoid::Relations::Referenced::In.

When the ids has been duplicated:

```ruby
@person = Person.create
@posts = 100.times { @person.posts.create }

Post.includes(:person)
# => find({"_id" => {"$in" => [BSON::ObjectId(snip) x 100]}})
```

Will be as follows: When you apply this patch.

```ruby
Post.includes(:person)
# => find({"_id" => {"$in" => [BSON::ObjectId(snip)]}})
```

Is it possible for you to merge this patch into your repository?

Regards,
Dai Akatsuka.