From 8786b5eed1843694e1c46ae1cc38e6ac8d9f396a Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Mon, 20 Dec 2021 02:54:04 +0900 Subject: [PATCH] For Ruby < 2.4 --- .../lib/kaminari/activerecord/active_record_relation_methods.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kaminari-activerecord/lib/kaminari/activerecord/active_record_relation_methods.rb b/kaminari-activerecord/lib/kaminari/activerecord/active_record_relation_methods.rb index eab9425..cf5503a 100644 --- a/kaminari-activerecord/lib/kaminari/activerecord/active_record_relation_methods.rb +++ b/kaminari-activerecord/lib/kaminari/activerecord/active_record_relation_methods.rb @@ -65,7 +65,7 @@ module Kaminari if @arel case @arel.limit.class.name - when 'Integer' + when 'Integer', 'Fixnum' @arel.limit = new_limit when 'ActiveModel::Attribute::WithCastValue' # comparing by class name because ActiveModel::Attribute::WithCastValue is a private constant @arel.limit = build_cast_value 'LIMIT', new_limit