Skip to content
#

validation

Here are 3,912 public repositories matching this topic...

h3llrais3r
h3llrais3r commented Jun 25, 2021

Describe the bug
The isMobilePhone() validator should only validate mobile phone numbers.
Currently it seems that it also validates the local/regional fixed phone numbers.
Reference: https://en.wikipedia.org/wiki/Telephone_numbers_in_Belgium

Examples
Valid ones:

  • 0470123456
  • +32470123456
  • 32470123456

Invalid ones (but valid local/regional fixed phone numbers):

  • 02
renta
renta commented Mar 24, 2021

Package version eg. v9, v10:

github.com/go-playground/locales v0.13.0
github.com/go-playground/universal-translator v0.17.0
github.com/go-playground/validator/v10 v10.2.0

Issue, Question or Enhancement:

Golangci-lint (https://github.com/golangci/golangci-lint) comes with a errorlint linter (https://github.com/polyfloyd/go-errorlint). When I switched it on, I got this issue f

Improve this page

Add a description, image, and links to the validation topic page so that developers can more easily learn about it.

Curate this topic

Add this topic to your repo

To associate your repository with the validation topic, visit your repo's landing page and select "manage topics."

Learn more