sportradar-api 0.1.33 → 0.1.34

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: 38520fc109b307a4001aafa9234bc77e52ef538e
4
- data.tar.gz: 367e7dee54869a70407a13d778eba45381fd56c3
3
+ metadata.gz: f7e1ba38dc4bce7adaa6728bb8a8f27c2baf087b
4
+ data.tar.gz: cdfde44f1618ecfe593fa22a2ec0e4eb43d1ff0f
5
5
  SHA512:
6
- metadata.gz: 0b53bd6606b7c520afc8d112d3b06c9e921441a90efa053e5bf8adb8d657765e2114c21760d92d3252df7775134f052812f6f545fb57befcb630fee1f4ccef03
7
- data.tar.gz: 306813a77ca617e9a53307f85976a090d8463a5e01a010a0a5c371611337a73f36176127a740f2391f6d8448472566f0852c8435ebca46ba1fab3186bc9c66a5
6
+ metadata.gz: 6d4520f69a5cdb3f338c25694a0976318a772c26155c634bb6e071a0802ab6c243c57d54fadb63f648d7226582e3966c6d5319a31248e4bd048125c090e5e24e
7
+ data.tar.gz: d793a289b59ef10aa312b21ad4e5eedb653dd620fec5370cbf975b027546c7d6374ed66f24e20e7c2e6652082ac611da41c4578264f402e14274480a188d1018
@@ -1,14 +1,14 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sportradar-api (0.1.31)
4
+ sportradar-api (0.1.33)
5
5
  activesupport
6
6
  httparty (>= 0.14.0)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- activesupport (5.0.0)
11
+ activesupport (5.0.0.1)
12
12
  concurrent-ruby (~> 1.0, >= 1.0.2)
13
13
  i18n (~> 0.7)
14
14
  minitest (~> 5.1)
@@ -7,7 +7,7 @@ module Sportradar
7
7
  def initialize(data)
8
8
  @response = data
9
9
  set_stats
10
- # @player = Sportradar::Api::Nfl::Player.new(response) if response['name'] # this isn't used yet, and we need to determine a better solution
10
+ @player = Sportradar::Api::Nfl::Player.new(response) if response['name'] # this isn't used yet, and we need to determine a better solution
11
11
  end
12
12
 
13
13
  def players
@@ -7,7 +7,7 @@ module Sportradar
7
7
  @attempts = response["attempts"]
8
8
  @completions = response["completions"]
9
9
  @cmp_pct = response["cmp_pct"]
10
- @yards = response["yards"]
10
+ # @yards = response["yards"]
11
11
  @avg_yards = response["avg_yards"]
12
12
  @sacks = response["sacks"]
13
13
  @sack_yards = response["sack_yards"]
@@ -17,7 +17,8 @@ module Sportradar
17
17
  @rating = response["rating"]
18
18
  @longest_touchdown = response["longest_touchdown"]
19
19
  @air_yards = response["air_yards"]
20
- @net_yards = response["net_yards"] # passing net_yards is the correct measure for team stats, as it includes sack yardage. that is how NFL counts team yardage
20
+ @net_yards = response["net_yards"] # passing net_yards is the correct measure for team stats, as it includes sack yardage
21
+ @yards = response["net_yards"] # should look further into this, make sure this isn't a bad idea
21
22
  @redzone_attempts = response["redzone_attempts"]
22
23
  end
23
24
  end
@@ -38,9 +38,9 @@ module Sportradar
38
38
  @away = Sportradar::Api::Nfl::Team.new data["away"] || location["away"] if data["away"] || location["away"]
39
39
  @broadcast = Sportradar::Api::Nfl::Broadcast.new data["broadcast"] if data["broadcast"]
40
40
  if data["team"]
41
- both_stats = data["team"].map { |hash| [hash["id"], Sportradar::Api::Nfl::GameStatistic.new(hash)] }.to_h
42
- @home.stats = both_stats[@home.id]
43
- @away.stats = both_stats[@away.id]
41
+ @stats = data["team"].map { |hash| [hash["id"], Sportradar::Api::Nfl::GameStatistic.new(hash)] }.to_h
42
+ @home.stats = @stats[@home.id]
43
+ @away.stats = @stats[@away.id]
44
44
  end
45
45
  end
46
46
 
@@ -1,5 +1,5 @@
1
1
  module Sportradar
2
2
  module Api
3
- VERSION = "0.1.33"
3
+ VERSION = "0.1.34"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sportradar-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.33
4
+ version: 0.1.34
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Eggett