Skip to content

fix: metadata validator requires national number without leading zero#88

Merged
rubdos merged 2 commits intowhisperfish:mainfrom
thvdveld:fix/number-type-with-leading-zero
Oct 9, 2025
Merged

fix: metadata validator requires national number without leading zero#88
rubdos merged 2 commits intowhisperfish:mainfrom
thvdveld:fix/number-type-with-leading-zero

Conversation

@thvdveld
Copy link
Collaborator

@thvdveld thvdveld commented Oct 9, 2025

The validator for the number type first does a check with the following regex "[1-9]\\d{8}". We should pass the national (significant) number to the validator instead of the number with the leading zero.

@rubdos rubdos self-requested a review October 9, 2025 12:04
Copy link
Member

@rubdos rubdos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, makes a lot of sense.

This closes most of the 0-prefix issues? Or is that still a separate case?

@thvdveld
Copy link
Collaborator Author

thvdveld commented Oct 9, 2025

They were fixed in a separate PR (#86). I added the test cases in this PR as a separate commit.

Sorry, I was confused. I think it closes most of the 0-prefix issues. However, the formatter is still not correct, which is a separate issue.

@thvdveld
Copy link
Collaborator Author

thvdveld commented Oct 9, 2025

I checked, and this PR does not fix the 0-prefix issues. Only the number_type validator.

@rubdos rubdos merged commit 61133c7 into whisperfish:main Oct 9, 2025
6 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants