diff options
author | Joram Wilander <jwawilander@gmail.com> | 2016-02-24 08:37:45 -0500 |
---|---|---|
committer | Joram Wilander <jwawilander@gmail.com> | 2016-02-24 08:37:45 -0500 |
commit | c0677c190d8d8c0350c69156ab6518120a2af1d1 (patch) | |
tree | 30ee67923c2408e85e44e08802fecfb7d315861d /web/react | |
parent | b7aa65cedd64b705c4716594e5e8e3fdaddcbb70 (diff) | |
parent | 89e1b91020b351b98fe34b159c5596d3775af0cf (diff) | |
download | chat-c0677c190d8d8c0350c69156ab6518120a2af1d1.tar.gz chat-c0677c190d8d8c0350c69156ab6518120a2af1d1.tar.bz2 chat-c0677c190d8d8c0350c69156ab6518120a2af1d1.zip |
Merge pull request #2234 from hmhealey/plt1669
PLT-1669 Slightly increase requirements for a valid email on the client
Diffstat (limited to 'web/react')
-rw-r--r-- | web/react/utils/utils.jsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index fd250ad10..41d93174e 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -19,7 +19,7 @@ import {FormattedTime} from 'mm-intl'; export function isEmail(email) { // writing a regex to match all valid email addresses is really, really hard (see http://stackoverflow.com/a/201378) // so we just do a simple check and rely on a verification email to tell if it's a real address - return email.indexOf('@') !== -1; + return (/^.+@.+$/).test(email); } export function cleanUpUrlable(input) { |