remove extra useless map

This commit is contained in:
Samuel Newman
2025-01-19 23:02:46 +00:00
parent 1ac172c08c
commit f28d139db0
+2 -5
View File
@@ -193,16 +193,14 @@ function Feed() {
usePostFeedQuery(
feedDesc,
params.type === 'feedgen' && params.sourceInterstitial !== 'none'
? {
feedCacheKey: params.sourceInterstitial,
}
? {feedCacheKey: params.sourceInterstitial}
: undefined,
)
const videos = useMemo(() => {
let vids =
data?.pages
.map(page => {
.flatMap(page => {
const items: {
_reactKey: string
moderation: ModerationDecision
@@ -221,7 +219,6 @@ function Feed() {
}
return items
})
.flatMap(items => items)
.filter(item => AppBskyEmbedVideo.isView(item.post.embed)) || []
const startingVideoIndex = vids?.findIndex(video => {
return video.post.uri === params.initialPostUri