add some common typos
This commit is contained in:
@@ -31,6 +31,9 @@ function sanitizeDate(date: Date): Date {
|
|||||||
return date
|
return date
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const COMMON_ERROR_PATTERN =
|
||||||
|
/\b([a-zA-Z0-9._%+-]+)@(gnail\.com|gmaill\.com|gmai\.com|gmail\.co|gmal\.com|iclod\.com|icloud\.co|outllok\.com|outlok\.com|outlook\.co|yaoo\.com|yaho\.com|yahoo\.co|yahooo\.com)\b/
|
||||||
|
|
||||||
export function StepInfo({
|
export function StepInfo({
|
||||||
onPressBack,
|
onPressBack,
|
||||||
isServerError,
|
isServerError,
|
||||||
@@ -68,7 +71,7 @@ export function StepInfo({
|
|||||||
|
|
||||||
if (!hasWarnedEmail && tldtsRef.current) {
|
if (!hasWarnedEmail && tldtsRef.current) {
|
||||||
const isIcann = tldtsRef.current.parse(email).isIcann
|
const isIcann = tldtsRef.current.parse(email).isIcann
|
||||||
if (!isIcann) {
|
if (!isIcann || COMMON_ERROR_PATTERN.test(email)) {
|
||||||
setHasWarnedEmail(true)
|
setHasWarnedEmail(true)
|
||||||
return dispatch({
|
return dispatch({
|
||||||
type: 'setError',
|
type: 'setError',
|
||||||
|
|||||||
Reference in New Issue
Block a user