Open
Description
Description
It seems that isPhoneNumber
function ignoring region
argument when phone number with calling code is passed.
Everything is okay when I am passing number without calling code for example:
isPhoneNumber('793921111', 'US') // false
but when I am passing region and number with calling code it seems that region
is ignored and calling code is treated as region
parameter:
isPhoneNumber('+48793921111', 'US') // true
note: 793921111
is valid polish number
Expected behavior
region
parameter is not ignored when number with calling code is passed as first argument
Actual behavior
region
parameter is ignored when number with calling code is passed as first argument