fast_page 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5cbe26206c49286c01fcab014490db153e8f365e3b8e4338e5bfba6bf6085883
4
- data.tar.gz: 89d213a8260026721de817d56f9692d5691ccd250aeee229dad86d9fe2f6a7e5
3
+ metadata.gz: 1a33bbdfaf50bfeb97b7cc4a59f478fac909824626370408a48725767ce34e88
4
+ data.tar.gz: 409beebed7fe6a62e30cecd8a9f7be7d012c1c18d00dac7aaa4330754fb72618
5
5
  SHA512:
6
- metadata.gz: 47a1122b7eddcc8e1eb4961c5abb5f56926b39255ee3be5321a8a56541a2bdfd7b1de4bb4e714469412238d1c8253d3e891444408694c402dbc86718048a202d
7
- data.tar.gz: 1242c919d036ccc33de101a41358fa7de1150e5a253deead5d538cb6bdce164554fbc4de8cf8d749693de9940dfbf1d725d111f9498b7037eee388c612129d71
6
+ metadata.gz: 50b32552555ef5d1f3d247bdd9b784991e5cf9095113c583256b68f11f2af0be4ccd40afc44fdbe5e00d81ebd3d797015b24ead10eee912b3833fc5a169a3d45
7
+ data.tar.gz: 4d3c40ab2b0d33ed32a36a24f206e66a2e71cb0190214a76e22ccf3a45dc83a409cfe9b8dbedecd7d5a52fc9af8a475889efe8aa6de58116a43bec8905974bfa
@@ -14,9 +14,14 @@ jobs:
14
14
  licensing:
15
15
  runs-on: ubuntu-latest
16
16
  steps:
17
- - uses: actions/checkout@v2
17
+ - uses: actions/checkout@v3
18
18
  with:
19
19
  fetch-depth: 0
20
- - run: sudo gem install license_finder && sudo gem install bundler
20
+ - name: Set up Ruby
21
+ uses: ruby/setup-ruby@v1
22
+ with:
23
+ ruby-version: 3.1.2
24
+ bundler-cache: false
21
25
  - run: bundle install
26
+ - run: gem install license_finder
22
27
  - run: license_finder
@@ -6,11 +6,12 @@ jobs:
6
6
  build:
7
7
  runs-on: ubuntu-latest
8
8
  steps:
9
- - uses: actions/checkout@v2
9
+ - uses: actions/checkout@v3
10
10
  - name: Set up Ruby
11
11
  uses: ruby/setup-ruby@v1
12
12
  with:
13
- ruby-version: 2.7.2
14
- bundler-cache: true
13
+ ruby-version: 3.1.2
14
+ bundler-cache: false
15
+ - run: bundle install
15
16
  - name: Run the default task
16
17
  run: bundle exec rake
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- fast_page (0.1.3)
4
+ fast_page (0.1.5)
5
5
  activerecord
6
6
  activesupport
7
7
 
@@ -11,7 +11,7 @@ module FastPage
11
11
  @values[:limit] = limit_value + 1 if limit_value
12
12
  id_scope = dup
13
13
  id_scope = id_scope.except(:includes) unless references_eager_loaded_tables?
14
- ids = id_scope.pluck(:id)
14
+ ids = id_scope.pluck(primary_key)
15
15
 
16
16
  if limit_value
17
17
  @values[:limit] = limit_value - 1
@@ -26,7 +26,7 @@ module FastPage
26
26
  return self
27
27
  end
28
28
 
29
- @records = where(id: ids).unscope(:limit).unscope(:offset).load
29
+ @records = where(primary_key => ids).unscope(:limit).unscope(:offset).load.records
30
30
  @loaded = true
31
31
 
32
32
  self
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module FastPage
4
- VERSION = "0.1.4"
4
+ VERSION = "0.1.6"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fast_page
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Coutermarsh
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-09-13 00:00:00.000000000 Z
11
+ date: 2023-07-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord