funky 0.2.15 → 0.2.16

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: 603440bcd5f540d026cb62990150a94d8a036fd3
4
- data.tar.gz: 1d0c8842a8872eceeb057cfdc8a74a39de5f4e8b
3
+ metadata.gz: ca9e59faa72e0eb097bef057e1b91e548cdc013d
4
+ data.tar.gz: 24aa6cdd8306a6396205b844145dcd62b5027967
5
5
  SHA512:
6
- metadata.gz: 7280ab0b2035dc879ffbba599b137aca3dba2e755912e436ce2472a12047900a33ac117e047e15cf0ad5099962e846ac9ec05bb9b4a3f48415b657a17723c9c2
7
- data.tar.gz: 80e5f20881c9a46d532b69bce9132bdcbcf7c06a2c494d9f96653e43f28dbd3ac572e829f196052be63cf5e169c65c34b8f5ebc48960c64e16657c0154f488f7
6
+ metadata.gz: b2426dcb4df32fa10e0615c889b9d1f642c331b68280c0d5cc89ad83860adff97c361a85fbfbbdc7ee4578e0c2d17d8aacdea7385575e1351efb5739ee7ea815
7
+ data.tar.gz: 7a0e74d6762a7bff04425b8a13c2dff867f54d58247ec848e7fa3e8dd97f504eb6dc1be61229e91bfd3dcfd5441eccdb92e4bd3826954c338fe3a6a21c540d5e
@@ -6,6 +6,10 @@ For more information about changelogs, check
6
6
  [Keep a Changelog](http://keepachangelog.com) and
7
7
  [Vandamme](http://tech-angels.github.io/vandamme).
8
8
 
9
+ ## 0.2.16 - 2017/04/02
10
+
11
+ * [ENHANCEMENT] Video.where(id: [..ids..]) now works even with more than 50 ids.
12
+
9
13
  ## 0.2.15 - 2017/03/21
10
14
 
11
15
  * [BUGFIX] Return a string for the description field of a Funky::Video
@@ -15,12 +15,14 @@ module Funky
15
15
 
16
16
  def self.fetch_and_parse_data(ids)
17
17
  if ids.is_a?(Array) && ids.size > 1
18
- response = Connection::API.batch_request(ids: ids, fields: fields)
18
+ ids.each_slice(50).inject([]) do |total, slice|
19
+ response = Connection::API.batch_request ids: slice, fields: fields
20
+ total += parse response
21
+ end
19
22
  else
20
23
  id = ids.is_a?(Array) ? ids.first : ids
21
- response = Connection::API.request(id: id, fields: fields)
24
+ parse Connection::API.request(id: id, fields: fields)
22
25
  end
23
- parse response
24
26
  rescue ContentNotFound
25
27
  []
26
28
  end
@@ -1,3 +1,3 @@
1
1
  module Funky
2
- VERSION = "0.2.15"
2
+ VERSION = "0.2.16"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: funky
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.15
4
+ version: 0.2.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philip Nguyen
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-03-21 00:00:00.000000000 Z
11
+ date: 2017-04-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -148,7 +148,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
148
148
  version: '0'
149
149
  requirements: []
150
150
  rubyforge_project:
151
- rubygems_version: 2.5.1
151
+ rubygems_version: 2.6.11
152
152
  signing_key:
153
153
  specification_version: 4
154
154
  summary: Funky is a Ruby library to fetch video data.