Sha256: fc9d0d37d5f47dc8f2e60b68b4b73428b59b943922254c031f14771bd2037dde

Contents?: true

Size: 460 Bytes

Versions: 4

Compression:

Stored size: 460 Bytes

Contents

# frozen_string_literal: true

module Goldiloader
  module Compatibility
    ACTIVE_RECORD_VERSION = ::Gem::Version.new(::ActiveRecord::VERSION::STRING).release

    def self.pre_rails_7?
      ::ActiveRecord::VERSION::MAJOR < 7
    end

    def self.rails_6_1?
      ::ActiveRecord::VERSION::MAJOR == 6 && ::ActiveRecord::VERSION::MINOR == 1
    end

    def self.rails_6_1_or_greater?
      ::ActiveRecord::VERSION::MAJOR > 6 || rails_6_1?
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
goldiloader-5.2.1 lib/goldiloader/compatibility.rb
goldiloader-5.2.0 lib/goldiloader/compatibility.rb
goldiloader-5.1.0 lib/goldiloader/compatibility.rb
goldiloader-5.0.0 lib/goldiloader/compatibility.rb