Skip to content

Commit

Permalink
update shouldShow
Browse files Browse the repository at this point in the history
  • Loading branch information
perunt committed Mar 8, 2023
1 parent cb4fc3b commit 46d6d40
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/pages/home/report/ContextMenu/ContextMenuActions.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const CONTEXT_MENU_TYPES = {
export default [
{
shouldKeepOpen: true,
shouldShow: (type, reportAction) => reportAction.actionName !== CONST.REPORT.ACTIONS.TYPE.IOU,
shouldShow: (type, reportAction) => type === CONTEXT_MENU_TYPES.REPORT_ACTION && _.has(reportAction, 'message') && reportAction.actionName !== CONST.REPORT.ACTIONS.TYPE.IOU,
renderContent: (closePopover, {
reportID, reportAction, close: closeManually, openContextMenu,
}) => {
Expand Down Expand Up @@ -73,11 +73,6 @@ export default [
);
}

const hasMessage = _.has(reportAction, 'message');
if (!hasMessage) {
// It happens when we long-press on a link. We can only provide a reaction for messages
return null;
}
return (
<QuickEmojiReactions
key="BaseQuickEmojiReactions"
Expand Down

0 comments on commit 46d6d40

Please sign in to comment.