Skip to content

Commit

Permalink
fix copy to clipboard error because action is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhardoj committed Oct 24, 2024
1 parent 866ce4b commit e4681b8
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ function BaseReportActionContextMenu({
draftMessage = '',
reportActionID,
reportID,
originalReportID,
checkIfContextMenuActive,
disabledActions = [],
setIsEmojiPickerActive,
Expand All @@ -120,7 +121,7 @@ function BaseReportActionContextMenu({
const {isProduction} = useEnvironment();
const threedotRef = useRef<View>(null);
const [betas] = useOnyx(ONYXKEYS.BETAS);
const [reportActions] = useOnyx(`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${reportID}`, {
const [reportActions] = useOnyx(`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${originalReportID}`, {
canEvict: false,
});
const transactionID = ReportActionsUtils.getLinkedTransactionID(reportActionID, reportID);
Expand Down Expand Up @@ -179,8 +180,6 @@ function BaseReportActionContextMenu({
const areHoldRequirementsMet =
!isInvoiceReport && isMoneyRequestOrReport && !ReportUtils.isArchivedRoom(transactionThreadReportID ? childReport : parentReport, parentReportNameValuePairs);

const originalReportID = useMemo(() => ReportUtils.getOriginalReportID(reportID, reportAction), [reportID, reportAction]);

const shouldEnableArrowNavigation = !isMini && (isVisible || shouldKeepOpen);
let filteredContextMenuActions = ContextMenuActions.filter(
(contextAction) =>
Expand Down

0 comments on commit e4681b8

Please sign in to comment.