zooqle_search 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/zooqle_search/search.rb +3 -2
- data/lib/zooqle_search/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15a7e692f31d9a9397a170c18d7c1715e6673df5
|
4
|
+
data.tar.gz: 6933fa77e4b99077b8674ba02907b2ca2f56ac5a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8282182566a7ade46f87feadea7ce231b53da7a98e675fb797749fbce38f5f1cac180bc6b17e9cd204d8df114fbcf6fe22be58b894caf7cbb8e643b817dc093b
|
7
|
+
data.tar.gz: 78ddf1877436e49239dd06037fcd0e40c211277d4aae2f4d19d43dfa8d1053662e7dadbbcfd19bd8b18d916933ffaa856754c30226b0113b983dc5e8280a0ce8
|
data/lib/zooqle_search/search.rb
CHANGED
@@ -41,13 +41,14 @@ module ZooqleSearch
|
|
41
41
|
|
42
42
|
crawled_links.each do |link|
|
43
43
|
filename = link.at('a').text
|
44
|
-
|
44
|
+
seeders_leechers = link.at('div[title^="Seeders:"]')
|
45
|
+
next if filename.strip.empty? || seeders_leechers.nil?
|
45
46
|
|
46
47
|
size = link.at('.progress-bar').text
|
47
48
|
magnet = link.at('a[title="Magnet link"]')['href']
|
48
49
|
download_url = BASE_URL + link.at('a[title="Generate .torrent"]')['href']
|
49
50
|
|
50
|
-
seeders_leechers =
|
51
|
+
seeders_leechers = seeders_leechers['title']
|
51
52
|
seeders = seeders_leechers[/Seeders: (?<seeders>[\d,]+) \| Leechers: (?<leechers>[\d,]+)/, :seeders]
|
52
53
|
leechers = seeders_leechers[/Seeders: (?<seeders>[\d,]+) \| Leechers: (?<leechers>[\d,]+)/, :leechers]
|
53
54
|
|