Sha256: c264df450c9187c5b40596d05107743ff7e3c285232962ed4806e01bd8f4779c

Contents?: true

Size: 384 Bytes

Versions: 2

Compression:

Stored size: 384 Bytes

Contents

module Mongoid
  module Compatibility
    module Version
      module ClassMethods
        (2..5).each do |v|
          const_set "V#{v}", Mongoid::VERSION =~ Regexp.new("^#{v}\.")

          define_method "mongoid#{v}?" do
            !!Mongoid::Compatibility::Version::ClassMethods.const_get("V#{v}")
          end
        end
      end

      extend ClassMethods
    end
  end
end

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
ish_lib_manager-0.0.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/mongoid-compatibility-0.3.1/lib/mongoid/compatibility/version.rb
mongoid-compatibility-0.3.1 lib/mongoid/compatibility/version.rb