validator.js
validator.js copied to clipboard
regex added for Senegal sn-SN
Validations added for Senegal - Issue https://github.com/validatorjs/validator.js/issues/1761
- isMobilePhone regex added for 'sn-SN'. Reference -Telephone_numbers_in_Senegal
- isPostalCode regex added for 'SN'. Reference
- Relevant unit test added & Readme updated.
CHECKLIST
- [x] PR contains only changes related; no stray files, etc.
- [x] README updated (where applicable)
- [x] Tests written (where applicable)
Codecov Report
All modified lines are covered by tests :white_check_mark:
Comparison is base (
b958bd7
) 99.95% compared to head (011da84
) 99.95%.
Additional details and impacted files
@@ Coverage Diff @@
## master #2304 +/- ##
==========================================
- Coverage 99.95% 99.95% -0.01%
==========================================
Files 107 107
Lines 2454 2449 -5
Branches 619 619
==========================================
- Hits 2453 2448 -5
Partials 1 1
Files | Coverage Δ | |
---|---|---|
src/lib/isMobilePhone.js | 100.00% <ø> (ø) |
|
src/lib/isPostalCode.js | 100.00% <ø> (ø) |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.