Skip to content

Commit

Permalink
useMemo removed for simple calculations. changes to these props were …
Browse files Browse the repository at this point in the history
…not picked up if new events changed their result (elastic#142810) (elastic#142814)

Co-authored-by: Karl Godard <[email protected]>
(cherry picked from commit 275da54)

Co-authored-by: Karl Godard <[email protected]>
  • Loading branch information
kibanamachine and mitodrummer authored Oct 6, 2022
1 parent 7be7037 commit 195c262
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ export function ProcessTreeNode({
}, [selectedProcess, process, childrenExpanded]);

const alerts = process.getAlerts();
const hasAlerts = useMemo(() => !!alerts.length, [alerts]);
const hasOutputs = useMemo(() => process.hasOutput(), [process]);
const hasAlerts = !!alerts.length;
const hasOutputs = process.hasOutput();
const hasInvestigatedAlert = useMemo(
() =>
!!(
Expand Down

0 comments on commit 195c262

Please sign in to comment.