ani-api 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/ani-api.rb +4 -3
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: faeae317c72ef02ae32b46cb7db48d606c6aa6c96c23287e8d89f4c8424646fc
4
- data.tar.gz: a679dcdb6d9933b371e8bc19bcaad237480d710ab4d5fc4b0451a17fb3806c82
3
+ metadata.gz: aa6f0004f34db7c79114c0169704961074d84bf39f085f58d8ae2776e6a907cd
4
+ data.tar.gz: 10fd87c0deab03c8e620bf2f729a149befa33970f8c9eedc4d705e649f0d9c87
5
5
  SHA512:
6
- metadata.gz: f5bd38cfe906be40c1518db42f1edec8b7cf8e9958529c9e61faa269864eea083d895e80a327dab87a41c9bf9f973c1c12e028c2fccf133202369996dfb05238
7
- data.tar.gz: eac1dd163ce6f13763a0f1cc027980e6500a070759b2f30a29559a7d537fcc6999821100708e04d87ff44719f86b96d2c184abbaf6640b78aa4e423d14f5c9a7
6
+ metadata.gz: cb9fb6f18c55a53d8af6fe6fc5280b03bb4ccd4778666870421f6de69424591627968bd96da8a7347f39b609fe44d475385826f5e268bcd240446780b5ec7fc4
7
+ data.tar.gz: 16be75e6331c91aede25e50bc028b4a08f2703c881daf8cb82b1d0d65f943c911588b50f79fe3a7e5ddabc7a7bd3205787ed275590d5832cbf3570034c9c3543
data/lib/ani-api.rb CHANGED
@@ -1,4 +1,3 @@
1
- # frozen_string_literal: true
2
1
  require 'net/http'
3
2
  require 'json'
4
3
 
@@ -18,6 +17,8 @@ class AniApi
18
17
  duration
19
18
  chapters
20
19
  volumes
20
+ genres
21
+ averageScore
21
22
  title {
22
23
  romaji
23
24
  english
@@ -40,7 +41,7 @@ class AniApi
40
41
  response = make_request(query, { id: id })
41
42
  @rate_limit = response['X-RateLimit-Remaining'].to_i
42
43
 
43
- JSON.parse(response.body)["data"]["Media"]
44
+ JSON.parse(response.body)["data"]["Media"].compact
44
45
  end
45
46
 
46
47
  def self.search(title)
@@ -82,4 +83,4 @@ class AniApi
82
83
  def self.rate_limit_remaining
83
84
  @rate_limit
84
85
  end
85
- end
86
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ani-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Fürst
@@ -35,5 +35,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
35
35
  requirements: []
36
36
  rubygems_version: 3.6.9
37
37
  specification_version: 4
38
- summary: A ruby gem that handles communication with the Anilist api
38
+ summary: A ruby gem that handles communication with the Anilist API
39
39
  test_files: []