From dfe40adb5756a2bedba39d0e688067f76086d678 Mon Sep 17 00:00:00 2001 From: Karolina Kosiorowska Date: Fri, 17 May 2024 07:53:10 +0200 Subject: [PATCH] Remove unnecessary `useCallback` --- .../components/shared/ActivitiesList/ActivitiesList.tsx | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/dapp/src/components/shared/ActivitiesList/ActivitiesList.tsx b/dapp/src/components/shared/ActivitiesList/ActivitiesList.tsx index 4df4c0c5a..3707d112f 100644 --- a/dapp/src/components/shared/ActivitiesList/ActivitiesList.tsx +++ b/dapp/src/components/shared/ActivitiesList/ActivitiesList.tsx @@ -28,12 +28,9 @@ function ActivitiesList(props: ListProps) { }, ONE_SEC_IN_MILLISECONDS) }, [activities]) - const handleItemDismiss = React.useCallback( - (activityId: string) => { - dispatch(deleteActivity(activityId)) - }, - [dispatch], - ) + const handleItemDismiss = (activityId: string) => { + dispatch(deleteActivity(activityId)) + } if (allActivities.length === 0) return null