mlb_rb 0.0.4 → 0.0.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9425c40e4217cb73a792654e606c3bf7f2433f666a4ce3d07a0f30a10429f073
4
- data.tar.gz: 5a9442a40f8e4a6b5b01545f31253159fce41a937b9922918e0fdfbf27020e12
3
+ metadata.gz: d8531eef783590d9d243f53f2f8a29f9cd0a590d8d4191a427c5a7997ea86f33
4
+ data.tar.gz: 496df599f736b806cc38aacb8df5543481d9a54eec849daa1fa6853e73bd00b5
5
5
  SHA512:
6
- metadata.gz: cb2cb494634507cf491832e7b6a2133e933c25867f034388c7b4617eca2fc1999a297109b5dc13a8b277f8537c59b0051041ed0b9f3a244d806e9d614ae46f9e
7
- data.tar.gz: fff2f9342f928a7df737e8b3b21d6c25ab5cf4a8a19d8b2d78e247e0ea9f8ffe309e42ddb3a23fbc07f16041c68e250b1c36163a5eb01c85e0bfc244b1c97526
6
+ metadata.gz: 87ce9910bc1b335c384f8fa2307929f73aeb7996db1d44381dc65f7cc177e767ec7e27b2b32213dc420c42b3f9b320f2cc8009435b2df045a69b72aef050aa81
7
+ data.tar.gz: f41dded18c3439711a3b101e308dbd315a7529939c16b8ab1fd4fd1495f99372efd7fb6f42a0c7f72ccc5ba88647559994942e0f07285d9c86405056db02875b
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.0.5] - 2022-04-09
4
+
5
+ - Change to only pull games that are final
6
+
3
7
  ## [0.0.4] - 2022-03-26
4
8
 
5
9
  - Clean up main class and extract games methods to MlbRb::Games class
data/lib/mlb_rb/client.rb CHANGED
@@ -13,8 +13,11 @@ module MlbRb
13
13
 
14
14
  def parse_games_by_date_response
15
15
  JSON.parse(json_response)["dates"].map do |date_hash|
16
- date_hash["games"].map { |game| Game.new(game) }
17
- end.flatten
16
+ date_hash["games"].map do |game|
17
+ final_state = game["status"]["detailedState"] == "Final"
18
+ Game.new(game) if final_state
19
+ end
20
+ end.flatten.compact
18
21
  end
19
22
 
20
23
  class << self
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MlbRb
4
- VERSION = "0.0.4"
4
+ VERSION = "0.0.5"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mlb_rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Miranda
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-03-26 00:00:00.000000000 Z
11
+ date: 2022-04-10 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email: