Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/pages/OnboardingWorkEmail/BaseOnboardingWorkEmail.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {useIsFocused} from '@react-navigation/native';
import {PUBLIC_DOMAINS_SET, Str} from 'expensify-common';
import {Str} from 'expensify-common';
import React, {useCallback, useEffect, useMemo, useState} from 'react';
import {View} from 'react-native';
import AutoEmailLink from '@components/AutoEmailLink';
Expand Down Expand Up @@ -108,7 +108,7 @@ function BaseOnboardingWorkEmail({shouldUseNativeStyles}: BaseOnboardingWorkEmai
const emailParts = userEmail.split('@');
Comment thread
daledah marked this conversation as resolved.
Resolved
const domain = emailParts.at(1) ?? '';

if ((PUBLIC_DOMAINS_SET.has(domain.toLowerCase()) || !Str.isValidEmail(userEmail)) && !isOffline) {
if (!Str.isValidEmail(userEmail) && !isOffline) {
Log.hmmm('User is trying to add an invalid work email', {userEmail, domain});
Comment thread
daledah marked this conversation as resolved.
Resolved
addErrorMessage(errors, INPUT_IDS.ONBOARDING_WORK_EMAIL, translate('onboarding.workEmailValidationError.publicEmail'));
Comment thread
daledah marked this conversation as resolved.
Resolved
}
Expand Down