From 5a86de5d139924bc86041d757bf4c6c6a03469b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?marcin=20miko=C5=82ajczak?= Date: Sun, 1 May 2022 21:36:29 +0200 Subject: [PATCH] Use useSettings hook MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: marcin mikołajczak --- app/soapbox/components/scrollable_list.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/soapbox/components/scrollable_list.tsx b/app/soapbox/components/scrollable_list.tsx index dd7b3f901..672520fa5 100644 --- a/app/soapbox/components/scrollable_list.tsx +++ b/app/soapbox/components/scrollable_list.tsx @@ -1,9 +1,8 @@ import React from 'react'; import { Virtuoso, Components } from 'react-virtuoso'; -import { getSettings } from 'soapbox/actions/settings'; import PullToRefresh from 'soapbox/components/pull-to-refresh'; -import { useAppSelector } from 'soapbox/hooks'; +import { useSettings } from 'soapbox/hooks'; import LoadMore from './load_more'; import { Spinner, Text } from './ui'; @@ -63,7 +62,7 @@ const ScrollableList: React.FC = ({ placeholderComponent: Placeholder, placeholderCount = 0, }) => { - const settings = useAppSelector((state) => getSettings(state)); + const settings = useSettings(); const autoloadMore = settings.get('autoloadMore'); /** Normalized children */