Skip to content

Commit

Permalink
[Security Solution][Session view] - fix EuiButton key not unique thro…
Browse files Browse the repository at this point in the history
…wing error (elastic#199497)

## Summary

This PR fixes a very small console error because of a EuiButton key that
is not unique in the Session View component.

Before fix

https://github.com/user-attachments/assets/930adc5d-1505-43c1-ac2f-451172e803e5

After fix

https://github.com/user-attachments/assets/5a4a824d-d048-4822-a930-a30bb87336cc
(cherry picked from commit 3124a72)
  • Loading branch information
PhilippeOberti committed Nov 8, 2024
1 parent 71653b7 commit b8ff777
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ export const AlertButton = ({
{alertsCount > 1 ? ALERTS : ALERT}
{alertsCount > 1 &&
(alertsCount > MAX_ALERT_COUNT ? ` (${MAX_ALERT_COUNT}+)` : ` (${alertsCount})`)}
{alertIcons?.map((icon: string) => (
<EuiIcon className="alertIcon" key={icon} size="s" type={icon} />
{alertIcons?.map((icon: string, index: number) => (
<EuiIcon className="alertIcon" key={`${icon}-${index}`} size="s" type={icon} />
))}
<EuiIcon css={buttonArrow} size="s" type="arrowDown" />
</EuiButton>
Expand Down

0 comments on commit b8ff777

Please sign in to comment.