Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-5677

[Monkey Patch Removal] Remove Hash#to_criteria

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 9.0.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      Refer to MONGOID-5660 for context.
       
      Hash#to_criteria is a kernel Monkey patch that converts a Hash to a Criteria by currying its key-values to an initialized Criteria class. It looks like it was done in order to support passing in a hash as an arg to Criteria.merge!, there's not a major use for it otherwise (Criteria also doesn't define #to_h)
       
      PR raised: https://github.com/mongodb/mongoid/pull/5717

            Assignee:
            jamis.buck@mongodb.com Jamis Buck
            Reporter:
            shields@tablecheck.com Johnny Shields
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: