Skip to content

Commit

Permalink
Merge pull request Expensify#45994 from nkdengineer/fix/45967
Browse files Browse the repository at this point in the history
Fix app crashes when submitting track-expense to someone
  • Loading branch information
Beamanator authored Jul 23, 2024
2 parents 23dbd28 + a680ecc commit c47208e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pages/home/report/ReportActionItemContentCreated.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import useThemeStyles from '@hooks/useThemeStyles';
import * as ReportActionsUtils from '@libs/ReportActionsUtils';
import * as ReportUtils from '@libs/ReportUtils';
import * as TransactionUtils from '@libs/TransactionUtils';
import CONST from '@src/CONST';
import type {TranslationPaths} from '@src/languages/types';
import ONYXKEYS from '@src/ONYXKEYS';
import type * as OnyxTypes from '@src/types/onyx';
Expand Down Expand Up @@ -51,7 +52,7 @@ function ReportActionItemContentCreated({contextValue, parentReportAction, trans

const {report, action, transactionThreadReport} = contextValue;

const [policy] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY}${report.policyID ?? '-1'}`);
const [policy] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY}${report.policyID === CONST.POLICY.OWNER_EMAIL_FAKE ? '-1' : report.policyID ?? '-1'}`);
const [transaction] = useOnyx(`${ONYXKEYS.COLLECTION.TRANSACTION}${transactionID ?? '-1'}`);

const transactionCurrency = TransactionUtils.getCurrency(transaction);
Expand Down

0 comments on commit c47208e

Please sign in to comment.