Skip to content
This repository was archived by the owner on Jan 15, 2024. It is now read-only.
This repository was archived by the owner on Jan 15, 2024. It is now read-only.

Allow #count to take $hint option? #389

@ryana

Description

@ryana

Should this line also take into account options so that hints like this can be used:

=> #<Mongoid::Criteria
  selector: {"organization_id"=>BSON::ObjectId('556f2a9b77656271580c0000'), "last_active_at"=>{"$gte"=>1970-01-01 00:00:00 UTC}, "created_at"=>{"$gte"=>2015-08-24 23:56:58 UTC}}
  options:  {:hint=>{"organization_id"=>1, "type"=>1, "last_active_at"=>1, "created_at"=>1}}
  class:    CommunityMember
  embedded: false>

I'm more than happy to supply a PR w/ tests if so. Thx.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions