From b91cf5de5839bcc608c558a52a7787fc34c338e1 Mon Sep 17 00:00:00 2001 From: Greg Molnar Date: Sat, 10 Aug 2024 11:53:36 +0000 Subject: [PATCH] fix version comparison --- Gemfile | 2 +- lib/polyamorous/polyamorous.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile b/Gemfile index 577330c2..695a117e 100644 --- a/Gemfile +++ b/Gemfile @@ -3,7 +3,7 @@ gemspec gem 'rake' -rails = ENV['RAILS'] || '7-1-stable' +rails = ENV['RAILS'] || '7-2-stable' rails_version = case rails when /\// # A path diff --git a/lib/polyamorous/polyamorous.rb b/lib/polyamorous/polyamorous.rb index 9e558709..f1b759d2 100644 --- a/lib/polyamorous/polyamorous.rb +++ b/lib/polyamorous/polyamorous.rb @@ -15,7 +15,7 @@ module Polyamorous require 'polyamorous/activerecord/join_dependency' require 'polyamorous/activerecord/reflection' - if ::ActiveRecord.version > ::Gem::Version.new("7.1") + if ::ActiveRecord.version >= ::Gem::Version.new("7.2") require "polyamorous/activerecord/join_association_7_2" end