Sha256: 522da480e831393adade9353947aa7481d3b6db8b253405db06666f55f3404ff

Contents?: true

Size: 230 Bytes

Versions: 5

Compression:

Stored size: 230 Bytes

Contents

module Mongoid
  module Criterion
    class Selector< Hash
      def []=(key, value)
        key = "#{key}.#{::I18n.locale}" if fields[key.to_s].try(:type) == Mongoid::I18n::LocalizedField
        super
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
mongoid_i18n-0.5.1 lib/mongoid/i18n/criterion/selector.rb
mongoid_i18n-0.5.0 lib/mongoid/i18n/criterion/selector.rb
mongoid_i18n-0.4.0 lib/mongoid/i18n/criterion/selector.rb
mongoid_i18n-0.3.1 lib/mongoid/i18n/criterion/selector.rb
mongoid_i18n-0.3.0 lib/mongoid/i18n/criterion/selector.rb