From 0e0e7c22cb8bc785dcffadf1923cad9448c8c9b2 Mon Sep 17 00:00:00 2001 From: "Tom (plebeius.eth)" Date: Wed, 26 Feb 2025 23:10:55 +0100 Subject: [PATCH] unnecessary memoization --- src/views/board/board.tsx | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/src/views/board/board.tsx b/src/views/board/board.tsx index 7f910de6..c01736c2 100644 --- a/src/views/board/board.tsx +++ b/src/views/board/board.tsx @@ -56,16 +56,13 @@ const Board = () => { const { sortType } = useSortingStore(); const { timeFilterSeconds, timeFilterName } = useTimeFilter(); - const feedOptions: any = useMemo( - () => ({ - subplebbitAddresses, - sortType, - postsPerPage: isInAllView || isInSubscriptionsView ? 5 : 25, - ...(isInAllView || isInSubscriptionsView ? { newerThan: timeFilterSeconds } : {}), - filter: hideThreadsWithoutImages ? threadsWithoutImagesFilter : undefined, - }), - [subplebbitAddresses, sortType, timeFilterSeconds, isInAllView, isInSubscriptionsView, hideThreadsWithoutImages], - ); + const feedOptions = { + subplebbitAddresses, + sortType, + postsPerPage: isInAllView || isInSubscriptionsView ? 5 : 25, + ...(isInAllView || isInSubscriptionsView ? { newerThan: timeFilterSeconds } : {}), + filter: hideThreadsWithoutImages ? threadsWithoutImagesFilter : undefined, + }; const { feed, hasMore, loadMore, reset, subplebbitAddressesWithNewerPosts } = useFeed(feedOptions); const { accountComments } = useAccountComments();