From f68b15219fd02e23d965015201400138ed69d59d Mon Sep 17 00:00:00 2001
From: Hailey <me@haileyok.com>
Date: Fri, 27 Sep 2024 14:01:57 -0700
Subject: Remove Segment (#5518)

---
 src/view/com/lists/ProfileLists.tsx | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

(limited to 'src/view/com/lists/ProfileLists.tsx')

diff --git a/src/view/com/lists/ProfileLists.tsx b/src/view/com/lists/ProfileLists.tsx
index 117164413..27b7f94df 100644
--- a/src/view/com/lists/ProfileLists.tsx
+++ b/src/view/com/lists/ProfileLists.tsx
@@ -10,7 +10,6 @@ import {msg} from '@lingui/macro'
 import {useLingui} from '@lingui/react'
 import {useQueryClient} from '@tanstack/react-query'
 
-import {useAnalytics} from '#/lib/analytics/analytics'
 import {cleanError} from '#/lib/strings/errors'
 import {logger} from '#/logger'
 import {isNative, isWeb} from '#/platform/detection'
@@ -48,7 +47,6 @@ export const ProfileLists = React.forwardRef<SectionRef, ProfileListsProps>(
     ref,
   ) {
     const t = useTheme()
-    const {track} = useAnalytics()
     const {_} = useLingui()
     const [isPTRing, setIsPTRing] = React.useState(false)
     const opts = React.useMemo(() => ({enabled}), [enabled])
@@ -102,7 +100,6 @@ export const ProfileLists = React.forwardRef<SectionRef, ProfileListsProps>(
     }))
 
     const onRefresh = React.useCallback(async () => {
-      track('Lists:onRefresh')
       setIsPTRing(true)
       try {
         await refetch()
@@ -110,18 +107,16 @@ export const ProfileLists = React.forwardRef<SectionRef, ProfileListsProps>(
         logger.error('Failed to refresh lists', {message: err})
       }
       setIsPTRing(false)
-    }, [refetch, track, setIsPTRing])
+    }, [refetch, setIsPTRing])
 
     const onEndReached = React.useCallback(async () => {
       if (isFetching || !hasNextPage || isError) return
-
-      track('Lists:onEndReached')
       try {
         await fetchNextPage()
       } catch (err) {
         logger.error('Failed to load more lists', {message: err})
       }
-    }, [isFetching, hasNextPage, isError, fetchNextPage, track])
+    }, [isFetching, hasNextPage, isError, fetchNextPage])
 
     const onPressRetryLoadMore = React.useCallback(() => {
       fetchNextPage()
-- 
cgit 1.4.1

