lib/phonelib/core.rb in phonelib-0.2.3 vs lib/phonelib/core.rb in phonelib-0.2.4

- old
+ new

@@ -96,10 +96,10 @@ if phone.nil? || country.nil? # has to return instance of Phonelib::Phone even if no phone passed Phonelib::Phone.new(phone, @@phone_data) else detected = detect_and_parse_by_country(phone, country) - if passed_country.nil? && @@default_country && detected.impossible? + if passed_country.nil? && @@default_country && detected.invalid? Phonelib::Phone.new(phone, @@phone_data) else detected end end