iteraptor 0.8.1 → 0.8.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
  SHA1:
3
- metadata.gz: 6233b7b0b6e3df8f2a9d839325ce0bb0b98c71db
4
- data.tar.gz: b4253266ab34631d9f16a4f699cc75e418d683db
3
+ metadata.gz: 195bc8d3aa981fe3a07eb7b9fd8b5ed90cad61f4
4
+ data.tar.gz: 1a41e0a2733f5f515b9d4e1d88c58a22bac2b489
5
5
  SHA512:
6
- metadata.gz: 6727ba65fc3958b1aaa207146cdf1ce882cc5cd456ca42b1266e1b141c6c3a392d7758e1d240f9436d061c5f76af261003fb7da231ee445f32e648f5804159db
7
- data.tar.gz: aad08a5fb9bf7dc75d8dea35164a5c236d9061c4890d1d7204ac5c6a0d6c6686ebea8646598f0a2f6d5cd8485232ea5706eab00ee6a4c562d42334f1853e0d98
6
+ metadata.gz: 5807c5d3f97ec4f3624a42657fcd3afc7fd151b6ed2c90552c4ecfc74c729c0151caac590bb0dd0973655683034e2a16cd9f9577dd966846fd74fcd4c0914707
7
+ data.tar.gz: c6c16010e9f3468ec60971c07af8a209c0c3569b22d8dfdd610898eea758a2be7949016adaddd58cd295daf9fdb1d50caaf01e83facdb21d47aa9d9313334abe
@@ -1,3 +1,3 @@
1
1
  module Iteraptor
2
- VERSION = '0.8.1'
2
+ VERSION = '0.8.2'
3
3
  end
data/lib/iteraptor.rb CHANGED
@@ -34,12 +34,11 @@ module Iteraptor
34
34
 
35
35
  def compactar **params
36
36
  (is_a?(Array) ? compact : self).
37
- mapa(yield_all: true) do |p, (k, v)|
37
+ mapa(yield_all: true) do |_p, (k, v)|
38
38
  v.is_a?(Array) ? [k, v.compact] : [k, v]
39
39
  end.mapa(**params) do |parent, (k, v)|
40
40
  p = parent.split(H.iteraptor_delimiter(params)).last
41
- puts [p, parent, k, v].inspect
42
- (p.to_i.to_s != p && v.nil?) ? nil : [k, v]
41
+ p.to_i.to_s != p && v.nil? ? nil : [k, v]
43
42
  end.tap do |this|
44
43
  break {} if this.empty? && is_a?(Hash)
45
44
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iteraptor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.8.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aleksei Matiushkin