holden-iso_country_codes 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
data/iso_country_codes.gemspec
CHANGED
@@ -23,6 +23,7 @@ class IsoCountryCodes # :nodoc:
|
|
23
23
|
else
|
24
24
|
instance = all.select { |c| c.name.upcase == code }.first
|
25
25
|
if opts[:fuzzy]
|
26
|
+
instance = []
|
26
27
|
instance = all.select { |c| c.name.match(/^#{code}/i) }.all if instance.nil?
|
27
28
|
instance = all.select { |c| c.name.match(/#{code}/i) }.all if instance.nil?
|
28
29
|
end
|