map 2.5.1 → 2.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/lib/map.rb +8 -4
  2. data/map.gemspec +1 -1
  3. metadata +5 -5
data/lib/map.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  class Map < Hash
2
- Version = '2.5.1' unless defined?(Version)
2
+ Version = '2.6.0' unless defined?(Version)
3
3
  Load = Kernel.method(:load) unless defined?(Load)
4
4
 
5
5
  class << Map
@@ -48,8 +48,8 @@ class Map < Hash
48
48
 
49
49
  def coerce(other)
50
50
  case other
51
- when self
52
- return other
51
+ when Map
52
+ other
53
53
  else
54
54
  allocate.update(other.to_hash)
55
55
  end
@@ -229,7 +229,11 @@ class Map < Hash
229
229
 
230
230
  def self.convert_value(value)
231
231
  conversion_methods.each do |method|
232
- return coerce(value.send(method)) if value.respond_to?(method)
232
+ #return convert_value(value.send(method)) if value.respond_to?(method)
233
+ if value.respond_to?(method)
234
+ value = value.send(method)
235
+ break
236
+ end
233
237
  end
234
238
 
235
239
  case value
data/map.gemspec CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
  Gem::Specification::new do |spec|
5
5
  spec.name = "map"
6
- spec.version = "2.5.1"
6
+ spec.version = "2.6.0"
7
7
  spec.platform = Gem::Platform::RUBY
8
8
  spec.summary = "map"
9
9
  spec.description = "description: map kicks the ass"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: map
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 23
5
5
  prerelease:
6
6
  segments:
7
7
  - 2
8
- - 5
9
- - 1
10
- version: 2.5.1
8
+ - 6
9
+ - 0
10
+ version: 2.6.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Ara T. Howard
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-02-14 00:00:00 -07:00
18
+ date: 2011-02-16 00:00:00 -07:00
19
19
  default_executable:
20
20
  dependencies: []
21
21