RubyGems
npm
Organizations
Log in
Sign up
RubyGems
named_value_class
Versions diffs
0.4.1 → 0.4.2
named_value_class 0.4.1 → 0.4.2
Sign up to get
free
protection for your applications and to get access to all the features.
Files changed (2)
hide
show
data/lib/named_value_class.rb
+1
-1
metadata
+1
-1
data/lib/named_value_class.rb
CHANGED
Viewed
@@ -49,7 +49,7 @@ def NamedValueClass(klass_name,superclass, &block)
49
49
this = self
50
50
self.class.singleton_class.instance_eval do
51
51
@mapping ||= {}
52
-
@mapping[value] = this
52
+
@mapping[value] = this
unless @mapping[value]
53
53
end
54
54
55
55
named_values_collection << self
metadata
CHANGED
Viewed
@@ -1,7 +1,7 @@
1
1
--- !ruby/object:Gem::Specification
2
2
name: named_value_class
3
3
version: !ruby/object:Gem::Version
4
-
version: 0.4.
1
4
+
version: 0.4.
2
5
5
prerelease:
6
6
platform: ruby
7
7
authors: