catamphetamine / react-phone-number-input

React component for international phone number input
http://catamphetamine.gitlab.io/react-phone-number-input/
MIT License
914 stars 194 forks source link

Validates incorrect number like 12345.... for Indian number #386

Closed maazakn closed 2 years ago

maazakn commented 3 years ago

It is accepting 123456... as a valid number for country code of +91. Although it is not a valid number.

catamphetamine commented 3 years ago

Provide more details

maazakn commented 3 years ago

It is not working accurately with Indian Numbers, starting with the country code of +91. It only checks the number length but not the number itself.

For example, it accepts some random numbers like,

as a valid number.

catamphetamine commented 3 years ago

What do you mean by “ it accept s some random numbers ”

On Thu, 24 Jun 2021 at 20:47, Maaz Ahmed Khan @.***> wrote:

It is not working accurately with Indian Numbers, starting with the country code of +91. It only checks the number length but not the number itself.

For example, it accepts some random numbers like,

  • 123459876
  • 199212345

as a valid number.

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/catamphetamine/react-phone-number-input/issues/386#issuecomment-867832130, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADUP34J2ZGQ3F5LS4HFKULTUNVR5ANCNFSM47IHLO3Q .

b-hexsoul commented 3 years ago

It is not working accurately with Indian Numbers, starting with the country code of +91. It only checks the number length but not the number itself.

For example, it accepts some random numbers like,

  • 123459876
  • 199212345

as a valid number.

How exactly are they not valid?