Skip to content

Commit

Permalink
use double pipe
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhardoj committed Aug 27, 2024
1 parent ddbe832 commit c7d65ab
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/libs/actions/ReportActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ function clearReportActionErrors(reportID: string, reportAction: ReportAction, k
});

// If there's a linked transaction, delete that too
const linkedTransactionID = ReportActionUtils.getLinkedTransactionID(reportAction.reportActionID, originalReportID ?? '-1');
// eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
const linkedTransactionID = ReportActionUtils.getLinkedTransactionID(reportAction.reportActionID, originalReportID || '-1');
if (linkedTransactionID) {
Onyx.set(`${ONYXKEYS.COLLECTION.TRANSACTION}${linkedTransactionID}`, null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,8 @@ function PopoverReportActionContextMenu(_props: unknown, ref: ForwardedRef<Repor
typeRef.current = type;
reportIDRef.current = reportID ?? '-1';
reportActionIDRef.current = reportActionID ?? '-1';
originalReportIDRef.current = originalReportID ?? '-1';
// eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
originalReportIDRef.current = originalReportID || '-1';
selectionRef.current = selection;
setIsPopoverVisible(true);
reportActionDraftMessageRef.current = draftMessage;
Expand Down

0 comments on commit c7d65ab

Please sign in to comment.