Open Badabum opened 8 years ago
That does look wrong, but note that on the usual phone keypad 7=PQRS, 3=DEF, 2=ABC: so you'd turn SDAF into 7323 as you saw. (I think that is or was common in the US - they'd advertise numbers like "1 800 WDISNEY" and you'd dial 1 800 9247639 etc.) So it does look a deliberate transform, although I'm surprised it's on by default.
@RupW , yup, in my opinion this conversion must be one of the latest conditions during validation process, or even different method which you can use when you need to perform such conversion.
Hope someone helps Use string newNumber = PhoneNumberUtil.NormalizeDigitsOnly("+38093sdaf342");
I've tried to use this lib, but faced some weird (as for me) behavior. I have string with wrong telephone number
+38093sdaf342
, 380 is a code of Ukraine, but any non-digit characters is not allowed in Ukrainian numbers. Here is the function where I try to validate this number.Passed params to function
number=+38093sdaf342
,regionCode="UA"
. Ive seen that in created by
Parsefunction object property
NationalNumber` is set to 937323342. Why is it so? I thought that this number must be validated as invalid cause it contains not only digits. Is it a bug or an expected behavior?