api-pagination 4.6.0 → 4.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5d77fb4d992aae484c741d89235cf7cbdb998c3f
4
- data.tar.gz: e267de21b868427e1788392d7ceffd30cbee68f7
3
+ metadata.gz: d16ca31c576d642c0b2110effb4ee77bdf60c693
4
+ data.tar.gz: 6e4992bdc9067026484e952a44230a83f1c6eacd
5
5
  SHA512:
6
- metadata.gz: 4e68ca7f44c0729540fd32a98b5106c803c2cdd96a73fa77c52dfa179f5ed00f7f529259838ebc28d10172efe2f421d66feb303f99c3e5eeaf73e7db9acd2b87
7
- data.tar.gz: 3bec93cd7ff6bb0d33de4720317e6a459787758b4c7d952f4edd7757eb309769b207c829070f38ccad2643121bd8af052b89a92b9e985d92da2f4b15d79cde9a
6
+ metadata.gz: 20c99b689079c16fe6eb9f2052c9fc7229d70ba0310c47d6d0b30739a175b6f41c8c86b8a87f23da32038dae5321c47a4a8e9490a24a43b426716ceae6cb51bd
7
+ data.tar.gz: ceab1f71e2d225a28500d925caee3f77e7b097994679970c6949ad84db02e836ac4567e232bc3cf5bcb8bd970895149581966b8365e73051ebcb287902be901f
@@ -60,6 +60,8 @@ module ApiPagination
60
60
  if defined?(Sequel::Dataset) && collection.kind_of?(Sequel::Dataset)
61
61
  collection.paginate(options[:page], options[:per_page])
62
62
  else
63
+ supported_options = [:page, :per_page, :total_entries]
64
+ options = options.dup.keep_if { |k,v| supported_options.include?(k.to_sym) }
63
65
  collection.paginate(options)
64
66
  end
65
67
  end
@@ -2,7 +2,7 @@ module ApiPagination
2
2
  class Version
3
3
  MAJOR = 4
4
4
  MINOR = 6
5
- PATCH = 0
5
+ PATCH = 1
6
6
 
7
7
  def self.to_s
8
8
  [MAJOR, MINOR, PATCH].join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: api-pagination
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.6.0
4
+ version: 4.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Celis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-21 00:00:00.000000000 Z
11
+ date: 2017-05-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec