nyaa_anime 0.3.5 → 0.3.6

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: f518b15ce69ec5f31737ea1397faf9bb06e03474
4
- data.tar.gz: b27f33dfc42a5f04ab623af6360a3a31629d58da
3
+ metadata.gz: 9cf4a5f4fd7c88e19d9ee161ea0e6184909e71f0
4
+ data.tar.gz: bde9b108e3bc7cd07c80c5d387c8459f11dfdcdd
5
5
  SHA512:
6
- metadata.gz: 8b6d5d9abda47b9e4c24445f0d7d86a9b8cf755b8b13a8bac4af54143f498bc330270dfdbab77eda4e14b42f54d9fea55c986207b482c8bb6f2c14e603922312
7
- data.tar.gz: cba7241454d0c8783aec120290cdef9e1efcbca67e4d0a464182b36a87c86523c16602abaf33f6cef046eee8ffda4baaeb2f60081549090e54f26e8b67dd955a
6
+ metadata.gz: 49bc891e22b69b273004482ee14f569578105e0886e9129147edbacd9d57463c27fb716b4be57fb43d0ecbee8710e20cee9417741cc1907cd0eeac5ba767b2bb
7
+ data.tar.gz: a4cd398f26d9e87c0d165b9f81dad675fc270160f2e0013c50d3b0895bda6ccc3ddf1ef8d17a8026afdf1b885b5c16b528612ee03cb79c2dd56190a7163757a4
@@ -36,8 +36,8 @@ class NyaaAnime
36
36
  offset += THREAD_COUNT
37
37
  end
38
38
  end
39
- titles = titles.reduce(nil) { |a, b| b ? a.concat(b) : a }
40
- dl_urls = dl_urls.reduce(nil) { |a, b| b ? a.concat(b) : a }
39
+ titles = titles.reduce([]) { |a, b| b ? a.concat(b) : a }
40
+ dl_urls = dl_urls.reduce([]) { |a, b| b ? a.concat(b) : a }
41
41
  return if titles.empty?
42
42
  titles.each_with_index { |t, i| @downloads[t] = dl_urls[i] }
43
43
  @titles = titles.sort!
@@ -56,8 +56,8 @@ class NyaaAnime
56
56
  new_titles[i] = n.new_titles
57
57
  new_downloads[i] = n.downloads.select { |ti, dl| n.new_titles.include? ti }
58
58
  end
59
- new_titles = new_titles.reduce(nil) { |a, b| b ? a.merge(b) : a }
60
- new_downloads = new_downloads.reduce(nil) { |a, b| b ? a.merge(b) : a }
59
+ new_titles = new_titles.reduce(Set.new) { |a, b| b ? a.merge(b) : a }
60
+ new_downloads = new_downloads.reduce({}) { |a, b| b ? a.merge(b) : a }
61
61
  @new_titles = new_titles
62
62
  @titles = new_titles.to_a.sort!
63
63
  @downloads = new_downloads
@@ -1,3 +1,3 @@
1
1
  class NyaaAnime
2
- VERSION = "0.3.5"
2
+ VERSION = "0.3.6"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nyaa_anime
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joshua Tsubaki Wu