uvdesk / mailbox-component

The Mailbox component provides tools that allows your helpdesk to process tickets from multiple email sources.
MIT License
22 stars 38 forks source link

Fix email validation #63

Closed bessone closed 3 years ago

bessone commented 3 years ago

1. Why is this change necessary?

Email validation uses a regex that doesn't accept the latest TLDs, such as .support. The TLD limit is 4 characters

2. What does this change do, exactly?

The code modification replaces the regex with a more complete and recent one, to try to use a standard, I used the one used by the HTML standard for validating inputs in HTML5 https://html.spec.whatwg.org/multipage/input.html#e-mail-state-(type%3Demail)

3. Please link to the relevant issues (if any).

62

papnoisanjeev commented 3 years ago

@bessone

We have updated file as per your pull request. You can see here.

bessone commented 3 years ago

Thanks @papnoisanjeev ! I'm just a little sad that my very small contribution doesn't officially appear on the project :'(