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

Field names display and options are on prohibited_methods list

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 6.2.0
    • Fix Version/s: 7.0.0, 6.2.1
    • Component/s: None
    • Labels:
      None
    • Environment:
      All

      Description

      Is it possible that this is a bug, since they are quite often used as field names.

      Mongoid::Errors::InvalidField (
      translation missing: sl.mongoid.errors.messages.message_title:
      translation missing: sl.mongoid.errors.messages.invalid_field.message
      translation missing: sl.mongoid.errors.messages.summary_title:
      translation missing: sl.mongoid.errors.messages.invalid_field.summary
      translation missing: sl.mongoid.errors.messages.resolution_title:
      translation missing: sl.mongoid.errors.messages.invalid_field.resolution):

      vendor/ruby/2.3.0/gems/mongoid-6.2.0/lib/mongoid/fields/validators/macro.rb:75:in `block in validate_name'
      vendor/ruby/2.3.0/gems/mongoid-6.2.0/lib/mongoid/fields/validators/macro.rb:73:in `each'
      vendor/ruby/2.3.0/gems/mongoid-6.2.0/lib/mongoid/fields/validators/macro.rb:73:in `validate_name'
      vendor/ruby/2.3.0/gems/mongoid-6.2.0/lib/mongoid/fields/validators/macro.rb:35:in `validate'
      vendor/ruby/2.3.0/gems/mongoid-6.2.0/lib/mongoid/fields.rb:268:in `field'

      Works fine in 6.1.1.

      by
      TheR

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              emily.stolfo Emily Stolfo
              Reporter:
              ther Damjan Rems
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: