Closed Seb33300 closed 5 years ago
Hello,
When the WS is unavailable, the VAT number is always considered as valid: https://github.com/ibericode/vat-bundle/blob/master/src/Validator/Constraints/VatNumberValidator.php#L39
You should at least provide a minimal control to check if the provided VAT number format is valid (starting with a valid country code and following by digits).
You can also provide a more or less strict control depending on the country code: https://en.wikipedia.org/wiki/VAT_identification_number#European_Union_VAT_identification_numbers
Thank you for your work.
My bad.
Just found out the control is done in the library. This is just the Symfony bundle...
https://github.com/ibericode/vat/blob/master/src/Validator.php#L15
Thank you
Hello,
When the WS is unavailable, the VAT number is always considered as valid: https://github.com/ibericode/vat-bundle/blob/master/src/Validator/Constraints/VatNumberValidator.php#L39
You should at least provide a minimal control to check if the provided VAT number format is valid (starting with a valid country code and following by digits).
You can also provide a more or less strict control depending on the country code: https://en.wikipedia.org/wiki/VAT_identification_number#European_Union_VAT_identification_numbers
Thank you for your work.