typed_params 1.0.1 → 1.0.2

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: 26b2e5feb7cf9a5dee31da13a451af45b0995fd586593d5ad0aff3619dbae7fb
4
- data.tar.gz: b0c56e75dfa90e7252d088a848155631bd943707c2d64628d366275c040b319f
3
+ metadata.gz: 2c59b3bb4616ea961712403ef227a38d003dcc3f1ee9a6d84f310b853c67ebd0
4
+ data.tar.gz: '092c41c550392b86b7a54355d061c2a6580181a3e9c7cd159035628edcf42459'
5
5
  SHA512:
6
- metadata.gz: 2ae0982eefae7e30a6f1d11bc3bf9494c9b94d752f3eb9b130d614a32c19c1b8795c3d2a25c34e50d66171d3a2aa84fbaa4137e6f78454d87da25dfbf30dd478
7
- data.tar.gz: 6abda1500599b0d982b3808108efc1e9fff777316c5d158bcfe4aadad88612df9ccdc3e63cd2991ecb1c64f72145ae08fd60c9be262d774f14dac29a974a9c86
6
+ metadata.gz: a8861eadab77356645756dbac358566ad33e872132ac9c68b29a8769c653806a0aa7487d81cf65a4a8046720a9389a20c75d4db0009418d785d844a0a908efff
7
+ data.tar.gz: ac7f14c76deb864aad8d11a3cf3cb5e2a72567ab7bf781780b8822aacb68820a8965374f439dee63568bf0a01a197c0189951cbc898e1ef15bbf4bc8840f4eb6
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.0.2
4
+
5
+ - Fix parameterization of nil children.
6
+
3
7
  ## 1.0.1
4
8
 
5
9
  - Fix namespaced schemas.
@@ -31,6 +31,9 @@ module TypedParams
31
31
  :parent
32
32
 
33
33
  def parameterize_array_schema(key:, value:)
34
+ return parameterize_value(key:, value:) if
35
+ value.nil?
36
+
34
37
  param = Parameter.new(key:, value: [], schema:, parent:)
35
38
 
36
39
  value.each_with_index do |v, i|
@@ -53,6 +56,9 @@ module TypedParams
53
56
  end
54
57
 
55
58
  def parameterize_hash_schema(key:, value:)
59
+ return parameterize_value(key:, value:) if
60
+ value.nil?
61
+
56
62
  param = Parameter.new(key:, value: {}, schema:, parent:)
57
63
 
58
64
  value.each do |k, v|
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TypedParams
4
- VERSION = '1.0.1'
4
+ VERSION = '1.0.2'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: typed_params
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zeke Gabrielse