Skip to content

Commit

Permalink
revert detructuring
Browse files Browse the repository at this point in the history
  • Loading branch information
hungvu193 committed Oct 2, 2023
1 parent 38dd253 commit f20276f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/pages/settings/Security/TwoFactorAuth/Steps/VerifyStep.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable rulesdir/onyx-props-must-have-default */
import React, {useEffect} from 'react';
import {withOnyx} from 'react-native-onyx';
import {ScrollView, View} from 'react-native';
Expand All @@ -24,13 +23,14 @@ import {defaultAccount, TwoFactorAuthPropTypes} from '../TwoFactorAuthPropTypes'

const TROUBLESHOOTING_LINK = 'https://community.expensify.com/discussion/7736/faq-troubleshooting-two-factor-authentication-issues/p1?new=1';

const defaultSession = {
const defaultProps = {
account: defaultAccount,
session: {
email: null,
},
};

function VerifyStep({account = defaultAccount, session = defaultSession}) {
function VerifyStep({account, session}) {
const {translate} = useLocalize();

const formRef = React.useRef(null);
Expand Down Expand Up @@ -146,7 +146,9 @@ VerifyStep.propTypes = {
email: PropTypes.string.isRequired,
}),
};
VerifyStep.defaultProps = defaultProps;

// eslint-disable-next-line rulesdir/onyx-props-must-have-default
export default withOnyx({
account: {key: ONYXKEYS.ACCOUNT},
session: {key: ONYXKEYS.SESSION},
Expand Down

0 comments on commit f20276f

Please sign in to comment.