Skip to content

Commit

Permalink
fix empty actions popover button (#110015)
Browse files Browse the repository at this point in the history
  • Loading branch information
semd authored Aug 25, 2021
1 parent 48d8944 commit c34cbbc
Showing 1 changed file with 16 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -217,18 +217,22 @@ function ObservabilityActions({

const actionsMenuItems = useMemo(() => {
return [
timelines.getAddToExistingCaseButton({
event,
casePermissions,
appId: observabilityFeatureId,
onClose: afterCaseSelection,
}),
timelines.getAddToNewCaseButton({
event,
casePermissions,
appId: observabilityFeatureId,
onClose: afterCaseSelection,
}),
...(casePermissions?.crud
? [
timelines.getAddToExistingCaseButton({
event,
casePermissions,
appId: observabilityFeatureId,
onClose: afterCaseSelection,
}),
timelines.getAddToNewCaseButton({
event,
casePermissions,
appId: observabilityFeatureId,
onClose: afterCaseSelection,
}),
]
: []),
...(alertPermissions.crud ? statusActionItems : []),
];
}, [afterCaseSelection, casePermissions, timelines, event, statusActionItems, alertPermissions]);
Expand Down

0 comments on commit c34cbbc

Please sign in to comment.