util-params 0.2.3 → 0.2.4

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: 4b32430c80041470abe0de90fd3e31b26dd0baab
4
- data.tar.gz: 42cb3be6ca0caa8cb22d2d16b1f5c88fa0fe257a
3
+ metadata.gz: f368eeb54dffabb9a1edbd1cf7a0a88a12f9fbf5
4
+ data.tar.gz: 96ff89d272851c5b7af165d1aead1259c2f30da8
5
5
  SHA512:
6
- metadata.gz: f4848b55e636e7f910e79eff20b311dd53f2950728bb82761eed3ac495314a502cae1f237d3fd08dddedbdaf096baa4b85cc2705af4277dde338026574896a9e
7
- data.tar.gz: 2dce8107806b81402d458c922e8619fb7a65b13031cffda3b54dc759368842dde2ea882f5c1207ffa2db41e8ed318b27ea60f8adbb2617902be604ba076eceef
6
+ metadata.gz: 5c70d18e5737557be118aef18d7832ac368f026d8c2b5db8686b49e17c5f99877146dbaed24f45a5f6d9c72eb8175f41bcc3bf6596dec5e7e5a5ec3da6a4fc0a
7
+ data.tar.gz: 3b738ad72bfe215068e33e7f16c89150dc4ef53a60866def9a2d3cf2cd7c70ab6a00fffe51b4a7b3f4a0a9c8a234ba9ec12dd4aa2409ad70936dfbb3a0a3a643
@@ -233,6 +233,8 @@ module Util
233
233
  def _validate_object key, val, elements
234
234
  return nil if val.nil?
235
235
 
236
+ r = {}
237
+
236
238
  elements.map do |options|
237
239
  options ||= {}
238
240
  elem_key = options[:key]
@@ -241,8 +243,9 @@ module Util
241
243
  elem_require = options[:require]
242
244
  elem_val = _load_val val, elem_key, elem_default, elem_require
243
245
 
244
- _validate "#{key}[#{elem_key}]", elem_type, elem_val, options
246
+ r[elem_key] = _validate("#{key}[#{elem_key}]", elem_type, elem_val, options)
245
247
  end
248
+ r
246
249
  end
247
250
 
248
251
  # エラー追加
@@ -1,5 +1,5 @@
1
1
  module Util
2
2
  module Params
3
- VERSION = "0.2.3"
3
+ VERSION = "0.2.4"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: util-params
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - unchi
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-10-06 00:00:00.000000000 Z
11
+ date: 2016-10-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler