nx 0.1.3 → 0.1.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
  SHA256:
3
- metadata.gz: 860d0e3a899e4d301495e6810141328e64f1bd43aa2b710e251c722345439cf1
4
- data.tar.gz: d8616dacb3c1677aebc27b1552f012efa9cb6979a43185c780ec6115e208657b
3
+ metadata.gz: aed1a5183b1c6cb573ace7c09bafb8a17794d37a0f4654750f46e9051e512904
4
+ data.tar.gz: 14e6da7bd750f8d61584170722f7ec2815329694006f3cc3a40f71fb0eda7d40
5
5
  SHA512:
6
- metadata.gz: 0a23742695babfe1c03239f2c69c2b6b4eb7c2cb1533255cd080f925374ba5a34a0eb76132985aa713bd1e52ff75d755017ac9d8e4919e110455433c99f34035
7
- data.tar.gz: 29c7c2c5729e8ef957b6f555eabd2592ba12eedb5752a28c0fd72c19652ba205efaa6135cad62317c78509f67737c9cc5905e57704c25ec79e3e91bfd834448b
6
+ metadata.gz: 51a2e10ffe0e7266514382ac75fe8282881c4771f0e6b181de5f80e2021ce9b373d87fcfd619fc25664e49a69cd2ed34980ffbc8d233952418042d0a4559aef7
7
+ data.tar.gz: e0151e81d8ed4e6d7d3cf32c212dc5c34ae0ea718c00e56df61c44160eccec72b92ecbd3f410fa7332a76018744e41e22da104cc868566d6b4878696db7de18a
data/lib/nx.rb CHANGED
@@ -12,11 +12,14 @@ module Nx
12
12
 
13
13
  # set by path:
14
14
  keys[0..-2].each_with_index do |key, index|
15
- the_key = key.to_sym
15
+ the_key = key
16
+ the_key = yeild(the_key) if block_given?
16
17
  me = me[the_key] = me[the_key] || (keys[index + 1].class == String ? {} : [])
17
18
  end
18
19
 
19
- me[keys[-1].to_sym] = value
20
+ the_key = keys[-1]
21
+ the_key = yeild(the_key) if block_given?
22
+ me[the_key] = value
20
23
  end
21
24
 
22
25
  def get(path)
@@ -1,3 +1,3 @@
1
1
  module Nx
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.4"
3
3
  end
Binary file
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - afeiship
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-03-07 00:00:00.000000000 Z
11
+ date: 2020-03-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -60,7 +60,7 @@ files:
60
60
  - bin/setup
61
61
  - lib/nx.rb
62
62
  - lib/templates/version.rb
63
- - nx-0.1.2.gem
63
+ - nx-0.1.3.gem
64
64
  - nx.gemspec
65
65
  - package.json
66
66
  homepage: https://github.com/afeiship/nx
Binary file