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

Fix credit card validator to only remove dashes and spaces #672

Merged
merged 4 commits into from
Jun 29, 2017

Conversation

michaltk
Copy link
Contributor

The credit card validator is allowing invalid numbers through. It seems to be because it’s first removing all alpha characters and then validating that sanitized string.
Now, after the change, it will only remove dashes and spaces.

@michaltk michaltk force-pushed the more-creditcard-validator-fix branch 2 times, most recently from 914e89c to c20b512 Compare June 27, 2017 00:00
@profnandaa
Copy link
Member

This looks okay now, is it just the merge conflict?

@michaltk michaltk force-pushed the more-creditcard-validator-fix branch from c20b512 to 7db18de Compare June 28, 2017 20:38
@chriso
Copy link
Collaborator

chriso commented Jun 29, 2017

Thanks.

@chriso chriso merged commit a4d7157 into validatorjs:master Jun 29, 2017
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.

3 participants