gorilla-patch 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/gorilla-patch/hash.rb +8 -0
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a787dd5c74b109548f43bb4bd596e8a3636ca8bd
4
- data.tar.gz: dc6bca77019542a8123c4b9886b78bc3ce6f7599
3
+ metadata.gz: 42a30f16346ec6af2d381bc88f7c30190ca2ebb7
4
+ data.tar.gz: 60f9622c4422cef6dcc0bc6aa037333967be8018
5
5
  SHA512:
6
- metadata.gz: c95104711ff03680d77866e9dcabcc47040f6ec385dc48894af6ab39e49532ba7ed2bd75c48ace8bbc95431230e0680c0001db37a64804ef7550fc90d91e8405
7
- data.tar.gz: ed84ec1f229035b0c213c0a39917b39a12a3a69a4738553da48349cb7e4fab590b3d89e8294fe771c00a775de2207c052caf1146b3747ca274b0943b431d4113
6
+ metadata.gz: 0039919f79065a7fd287372e6ed8351bd5405369802b9e46290898533ba5d55a0945fd2151028dc5edbee350028c8f95e4d19a43265cfaa8b288cef83806939c
7
+ data.tar.gz: 5e7da9352295620397218804979cf026d765d38510e17ff45a027762550e34b6b3fe87dcbd3438d0b786a63c8e074b665a53e6b13f9ed8d194dfb38f854b0142
@@ -30,6 +30,14 @@ module GorillaPatch
30
30
  self
31
31
  end
32
32
 
33
+ def compact
34
+ dup.compact!
35
+ end
36
+
37
+ def compact!
38
+ delete_if { |_k, v| v.nil? }
39
+ end
40
+
33
41
  end
34
42
 
35
43
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gorilla-patch
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
  - Alexander Popov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-11 00:00:00.000000000 Z
11
+ date: 2015-09-17 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Refine Ruby Core classes.
14
14
  email: alex.wayfer@gmail.com