Skip to content

Commit e98bcef

Browse files
committed
Hotfix: undefined split
1 parent ed52b56 commit e98bcef

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/components/Modals/AddContactModal.jsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,11 @@ const AddContactModal = ({
7979
const [processing, setProcessing] = useState(false);
8080
const theme = useTheme();
8181
const isSmallScreen = useMediaQuery(theme.breakpoints.down('sm'));
82-
const [oidcProviders] = useState([...ENV.VITE_SUGGESTED_OIDC_OPTIONS.split(', '), 'Other']);
82+
const [oidcProviders] = useState(() =>
83+
ENV.VITE_SUGGESTED_OIDC_OPTIONS.split(', ') !== undefined
84+
? [...ENV.VITE_SUGGESTED_OIDC_OPTIONS.split(', '), 'Other']
85+
: ['Other']
86+
);
8387
const [Oidc, setOIDC] = useState('');
8488
const [isSubmittable, setIsSubmittable] = useState(false);
8589

0 commit comments

Comments
 (0)