Commit f0eae3d
committed
fix(i18n/ind): anchor ind_pan so trailing characters are rejected
ind_pan used re.match(r"[A-Z]{5}\d{4}[A-Z]{1}", ...) with no trailing $,
so any string starting with a valid PAN was accepted -- e.g.
ind_pan('ABCDE9999KEXTRA') returned a match. Anchor the pattern with
^...$, matching the ind_aadhar style just above it.1 parent 2d0074a commit f0eae3d
2 files changed
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
30 | 32 | | |
31 | 33 | | |
32 | 34 | | |
0 commit comments