Correctly validate colombian postal codes. #11
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The current implementation of the Colombian postal code validator is inaccurate.
While it is correct that there are 32 departments in Colombia, they do not have sequential codes ranging from 00 to 32. For instance, the department of Nariño has a code of 52. Additionally, it's important to highlight that Bogotá, the capital city, is a special district and has its own unique postal code.
I have thoroughly validated all postal codes in the test data set using the official site maintained by 4-72, the company that operates as the official postal service of Colombia. The site can be found at https://visor.codigopostal.gov.co/472/visor/.