hash_order_helper 0.1.4 → 0.1.5

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: 278e89e8913fdbfe4e9cab86ed0fc9032b138b00
4
- data.tar.gz: c74a334591c31d7b850d0fa773c0f4ceea6da16b
3
+ metadata.gz: fed8045b5b231e00e1742953907a8fe93a066ad7
4
+ data.tar.gz: f4c57105accbd38c51f3836b867e43dc60861660
5
5
  SHA512:
6
- metadata.gz: eb3d0c7868e9386b09233057ade12c935ba9a3ad910cd887b79d529f59e957a5e940b29e71c8da0192a55af7de548a95e276507b0a203b54f5d0ca0ac72ffb29
7
- data.tar.gz: 444e68e8e0b3d07f46938171a2011225f2bcd26a407116f82bd31ffb2f9e60e49b479d7fa0a996d32f7b4a6942e1988834d512e2bf382d456c5b4aa4e52e6070
6
+ metadata.gz: bc5b033d200678648b8a4644e8bf013d96e7775ed83e336c2e14b07cea972661eeece581899c350cdef33310e07462c51e77da8a37af4e9d35e9ea0bdeb4d92d
7
+ data.tar.gz: e51b1881becb9f6d4c0781bf52d96bfa77844a021a1c65ab10f6199ecc5c823461880906c14b3c4f9644ac7f757f525c9a7392c7d1777dfe8142b5b972756773
data/README.md CHANGED
@@ -46,12 +46,11 @@ The following methods are added:
46
46
  * `last(n) -> Array`
47
47
  * `pop -> Array`
48
48
  * `pop(n) -> Array` (alias: `<<`)
49
- * `nd_push(hash) -> Hash` **non-destructive** (alias: `<`)
49
+ * `nd_push(hash) -> Hash` **non-destructive** (alias: `+`)
50
50
  * `push(hash) -> Hash`
51
51
  * `nd_unshift(hash) -> Hash` **non-destructive**
52
52
  * `unshift(hash) -> Hash`
53
53
  * `>>(receiver_hash) -> Hash`
54
- * `>(receiver_hash) -> Hash` **non-destructive**
55
54
 
56
55
  ### `>>` method
57
56
 
@@ -1,7 +1,7 @@
1
1
  # coding: utf-8
2
2
  Gem::Specification.new do |spec|
3
3
  spec.name = 'hash_order_helper'
4
- spec.version = '0.1.4'
4
+ spec.version = '0.1.5'
5
5
  spec.authors = ['Genki Sugawara']
6
6
  spec.email = ['sugawara@cookpad.com']
7
7
 
@@ -76,7 +76,7 @@ module HashOrderHelper
76
76
 
77
77
  new_hash
78
78
  end
79
- alias < nd_push
79
+ alias + nd_push
80
80
 
81
81
  def push(push_hash)
82
82
  new_hash = nd_push(push_hash)
@@ -109,13 +109,5 @@ module HashOrderHelper
109
109
 
110
110
  receiver.unshift(self)
111
111
  end
112
-
113
- def >(receiver)
114
- unless receiver.is_a?(Hash)
115
- raise TypeError, "no implicit conversion of #{receiver.inspect}:#{receiver.class} into Hash"
116
- end
117
-
118
- receiver.nd_unshift(self)
119
- end
120
112
  end
121
- Hash.send(:prepend, HashOrderHelper)
113
+ Hash.send(:include, HashOrderHelper)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hash_order_helper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Genki Sugawara