Rik Smale

Results 361 comments of Rik Smale

If the format remains the same, and I now see that it should, then it's not an issue with adding indeed. Thanks for opening a PR for it!

This is due to https://github.com/validatorjs/validator.js/pull/2189 With that, can you figure out why it accepts those strings and what we need to change to fix it if that behaviour is incorrect?

Is there maybe a link by PostNL (the national postal carrier) that explains these rules that we can use as a source?

Yeah, I've seen these changes in various other maps but I was hoping for some better source. I'll try to search for them in the coming days before approving this...

Ah nice, and I see they have different countries as well. Could you add those in a separate PR?

Yes, master does not reflect our latest release but we have planned a new release that contains this fix. See https://github.com/validatorjs/validator.js/pull/2269

Thanks for the PR! Don't forget to add additional tests before we can review this

The PR that added the regex (https://github.com/validatorjs/validator.js/pull/2061) did not have any source. The page where you got that quote from is likely https://www.byevisa.com/azerbaijan-passport/ but that also does not have a...

Let's put this behind a new option for backwards compatibility. Some projects might use both for user input and then they expect a boolean returned instead of an error. So...

If it's set to true it should throw an Error, if it's set to false it will return false (the current behaviour)