pebblebed 0.3.19 → 0.3.20
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pebblebed/sinatra.rb +2 -2
- data/lib/pebblebed/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8310ad73ddbc179d054ac75fdf33890d51e3fa61
|
4
|
+
data.tar.gz: d60bca28ff3cce1676d00655f04a9717bcd65092
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2edd27c829d0567756bb27ff2d9e66401db37baad0c9ee35a5334ebcd8c2d740759137ea6e41812fbe5f8cef095d196eaeec39db071cbdf8b19a16309692c1d8
|
7
|
+
data.tar.gz: e75bbaef43db033a865b5e9965b818994bae9bf01ce379c8102143b83d74a13458a5645d84a05f494d93fa0f95e4b9cd50f3d7a8f1d352bb597d02c0c6df098d
|
data/lib/pebblebed/sinatra.rb
CHANGED
@@ -123,8 +123,8 @@ module Sinatra
|
|
123
123
|
def limit_offset_collection(collection, options)
|
124
124
|
limit = (options[:limit] || 20).to_i
|
125
125
|
offset = (options[:offset] || 0).to_i
|
126
|
-
collection = collection.limit(limit+1).offset(offset)
|
127
|
-
last_page = (collection.
|
126
|
+
collection = collection.limit(limit+1).offset(offset).to_a
|
127
|
+
last_page = (collection.length <= limit)
|
128
128
|
metadata = {:limit => limit, :offset => offset, :last_page => last_page}
|
129
129
|
collection = collection[0..limit-1]
|
130
130
|
[collection, metadata]
|
data/lib/pebblebed/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pebblebed
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.20
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Katrina Owen
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-
|
12
|
+
date: 2017-10-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rspec
|