- updated data
- dropped support of ruby < 2
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- added
Phonelib.additional_regexes
feature allowing to add custom regex patterns for certain types. This should help to overcome an issue when pattern is still missing.
- updated data
- added ruby 3 support
- updated data
- added
Phonelib.sanitize_regex
config variable to control symbols for sanitizing during phone parsing
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
- fixed issue #152, incorrect formatting of MX
- updated data
- updated data
- adding
Phonelib.strict_double_prefix_check
configuration variable to disable sanitizing of double prefix on passed phone number
- added
==
method - updated data
- added option for
international
ande164
related methods to accept prefix parameter, which is "+" by default - updated data
- updated data
- updated data
- updated data
- added
valid_country_name
method to return country name where the parsed phone comes from (in case it's valid) country_specifier
in validator can now be set as symbol and not only proc, review the documentation- updated data
- updated data
- updated data
- added
00
as an international prefix - updated data
- updated data
- added
:countries
validator key that checks whether validated phone is within specified countries - updated data
- added option to set multiple strings to
Phonelib.extension_separate_symbols
by passing an array. Refer to README. - updated data
- added national prefix transformation rule to parsing process
- updated data
- updated data
- updated data
- updated data
- updated data
- updated data
:extensions
option added to validator, once set tofalse
will perform additional check if parsed phone has extension
- updated data
- fixed
Phonelib.parse_special
behavior, now there is a real separation of checks - updated data
- updated data
- updated data
- added
Phone.to_s
method, it will returne164
in case number is valid ororiginal
otherwise - added
Phonelib.vanity_conversion
setting, that defines whether to convert chars in phone number to appropriate numbers. Default isfalse
- fixed missing spaces in
geo_name
method results - added
:country_specifier
parameter to validator, allows to specify country for validation (PR #97) - added
Phonelib.override_phone_data
for defining a file holding exceptions for google's libphonenumber library's data (PR #96)
- updated data
- allowing to pass
strict: true
to validator - added
raw_national
method for returning unformatted national number part of international number
- allowing + in the beginning of number when strict check is on
- updated data
- fixing to override default country when + passed in the beginning of phone
- fixed error when int passed as phone number
- fixed error when
";"
passed as phone number - fixed
area_code
method behaviour - changed documentation to yard
- fixed bug in
international
method when no country can be defined
- updated data
- added method
full_national
which returns national number with extension - fixed methods returning formatted numbers with extension not to put ";" sign in case extension is empty
- fixed
international
ande164
methods to return number with country code if it's not present in number
- updated data
- fixed bad behaviour, when country valid regex didn't match, but some type's regex was matching
- added more strict behaviour when country passed - don't try to detect country when it was specified for parsing
- updated data
- added flag
Phonelib.strict_check
to disable sanitizing of phone number being passed for parsing - added boolean param for
national
andinternational
methods, iffalse
passed, it will return unformatted phone representation
- updated data
- fixed bug in validator for types when type is
:fixed_or_mobile
- added
full_e164
andfull_international
methods to return phone number with extensions - added
Phonelib.extension_separator=
method to define extension separator while formatting - added
Phonelib.extension_separate_symbols=
method to define extension separating symbols for parsing
- Fixed parsing with national code for CN
- Added setting to use special numbers types for phone parsing. Disabled by default. In order to enable use
Phonelib.parse_special = true
in initializer. - Fixed behaviour of double country codes in phones for IN, DE, BR
- Updated phone data
- Added method
valid_country
for returning country for parsed phone just in case phone number was valid - Changed behavior of method
country
, now it returns main country for international code in case there is such country, or first country from array - Added
local_number
method toPhone
, returns local number without area code - Added
area_code
method toPhone
, returns area code of phone or nil if none present for parsed number - Added
extension
method toPhone
, returns extension passed for parsing after#
or;
signs - Updated phones data
- Parsing of phone may return type
:fixed_or_mobile
even when patterns are different but valid for both:mobile
and:fixed_line
. Previously it could be only when patterns match - Added changelog
- Updated data and added test for TT phone