Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IBAN validation ignores non alphanumeric characters #283

Closed
antogyn opened this issue Apr 8, 2020 · 2 comments
Closed

IBAN validation ignores non alphanumeric characters #283

antogyn opened this issue Apr 8, 2020 · 2 comments

Comments

@antogyn
Copy link

antogyn commented Apr 8, 2020

Hey,

Because of this code:

function electronicFormat(iban: string): string {
return iban.replace(NON_ALPHANUM, '').toUpperCase();
}

Non alphanumeric characters aren't validated, e.g. IBANs like AL35 202$,;?111090000000001234567 pass validation and are returned as is.

I'd be ok to send a PR, but a fix would be a breaking change, so ignoring alphanumeric characters should probably stay the default behaviour. Any suggestion ?

@Urigo
Copy link
Owner

Urigo commented Apr 9, 2020

thank you @antogyn
We would love to get a PR that validates it.

If it's a broken behavior, fixing it doesn't consider a breaking change in terms of semver in my opinion..

@ardatan
Copy link
Collaborator

ardatan commented May 25, 2020

Available in v1.1.3

@ardatan ardatan closed this as completed May 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants