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

update email validation regex to be mostly RFC5322 compliant #46

Merged

Conversation

jpizzle34
Copy link
Contributor

@jpizzle34 jpizzle34 commented Jul 26, 2021

The current email validation being used succesfully validates isolated email strings, however it can be improved upon to be more RFC5322 compliant. For instance the current regex doesn't allow specifying an email string of the form Jane Citizen <jane.citizen@example.com>.

This pull request updates the regex test to be MOSTLY RFC5322 compliant.

The solution references the accepted answer to the following stack overflow question:
https://stackoverflow.com/questions/201323/how-can-i-validate-an-email-address-using-a-regular-expression?page=1&tab=votes#tab-top

@alexzaganelli alexzaganelli merged commit cd64140 into alexzaganelli:main Jul 26, 2021
@alexzaganelli
Copy link
Owner

Awesome 👏
Thank you @jpizzle34

@jpizzle34
Copy link
Contributor Author

jpizzle34 commented Jul 26, 2021 via email

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