nyaa-transmission 1.0.6 → 1.0.7

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
  SHA256:
3
- metadata.gz: 7652cb46a607367dca0fdb54d14eb089ab2a549967108f89f95b8ad01cb00e55
4
- data.tar.gz: f05163fae939be272cc9c01b9fb5e576d22e324bcd887a41b82999abd00cc334
3
+ metadata.gz: '087e8454525b4a7bb25d62b93e0cdb27dc456ce4a91c45a8249adeb1f644139e'
4
+ data.tar.gz: e6efcf67219d85dd9e4bafb7bcda6fbe0895d674cfed14b708df9914d983ec7b
5
5
  SHA512:
6
- metadata.gz: '09f28030eaff509845c5279735317b7a36e6e1ac565d99d9f6f742211251c265af0b27dd5f702379491dcefa4e32f5dfa0e4279fc3a4b9f4ba2b85bf80396583'
7
- data.tar.gz: fc3d0f3ada3bc3971de9f1bc0bc61e5476082829c2a8bdbf456aff9f2f6e0c2a6ab2350a7e9ac8e0f1a793d615b5aca140b4745056a416e1a04e0e54d49013a8
6
+ metadata.gz: 2037ae0345dd2ee6ee7bd8e3532ef2c7a94807d8321538ebac18ac36c3192cd514663224f142dbb4c0b3fc6ffb98b1d3de55e1138344e61b32c512a27501ae0b
7
+ data.tar.gz: 1b3e9b98a6ae8fc713be6b96658999f61d82b5a6d9b5ceaba2bcd2dc6df6e57dc67c2080800406e26ee07e88a4c57f9e7e454b8390f8c738cdf4994f5d6fee2a
@@ -20,21 +20,24 @@ module Nyaa::Category
20
20
  end
21
21
 
22
22
  class NyaaSearch
23
- attr_accessor :filter, :category, :query, :page
23
+ attr_accessor :filter, :category, :query, :user, :page
24
24
 
25
25
  def initialize(args={})
26
26
  self.filter = args[:filter] || Nyaa::Filter::NoFilter
27
27
  self.category = args[:category] || Nyaa::Category::AllCategories
28
28
  self.query = args[:query] || ""
29
+ self.user = args[:user] || nil
29
30
  self.page = args[:page] || 1
30
31
  end
31
32
 
32
33
  def querystring
33
- URI.encode_www_form(
34
+ form = {
34
35
  "f" => self.filter,
35
36
  "c" => self.category,
36
37
  "q" => self.query,
37
- "p" => self.page
38
- )
38
+ "p" => self.page,
39
+ "u" => self.user,
40
+ }
41
+ URI.encode_www_form(form.compact)
39
42
  end
40
43
  end
@@ -13,7 +13,8 @@ class HorribleSubs < Provider
13
13
  search_criteria = NyaaSearch.new(
14
14
  :filter => Nyaa::Filter::TrustedOnly,
15
15
  :category => Nyaa::Category::Anime::EnglishTranslated,
16
- :query => "HorribleSubs 1080p -batch #{series}",
16
+ :query => "1080p -batch #{series}",
17
+ :user => "HorribleSubs",
17
18
  :page => 1
18
19
  )
19
20
 
@@ -27,7 +28,8 @@ class EraiRaws < Provider
27
28
  search_criteria = NyaaSearch.new(
28
29
  :filter => Nyaa::Filter::TrustedOnly,
29
30
  :category => Nyaa::Category::Anime::EnglishTranslated,
30
- :query => "Erai-raws 1080p -\"~\" #{series}",
31
+ :query => "1080p -\"~\" #{series}",
32
+ :user => "Erai-raws",
31
33
  :page => 1
32
34
  )
33
35
 
@@ -41,7 +43,8 @@ class Blackjaxx < Provider
41
43
  search_criteria = NyaaSearch.new(
42
44
  :filter => Nyaa::Filter::NoFilter,
43
45
  :category => Nyaa::Category::Anime::EnglishTranslated,
44
- :query => "Blackjaxx 1080p -batch #{series}",
46
+ :query => "1080p -batch #{series}",
47
+ :user => "Blackjaxx",
45
48
  :page => 1
46
49
  )
47
50
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nyaa-transmission
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anthony Poon