Root post always avail here

This commit is contained in:
Eric Bailey
2024-08-14 17:24:03 -05:00
parent 8957783c2b
commit 87c4cfc705
+3 -3
View File
@@ -84,7 +84,7 @@ export function FeedItem({
rootPost,
}: FeedItemProps & {
post: AppBskyFeedDefs.PostView
rootPost?: AppBskyFeedDefs.PostView
rootPost: AppBskyFeedDefs.PostView
}): React.ReactNode {
const postShadowed = usePostShadow(post)
const richText = useMemo(
@@ -141,7 +141,7 @@ let FeedItemInner = ({
}: FeedItemProps & {
richText: RichTextAPI
post: Shadow<AppBskyFeedDefs.PostView>
rootPost?: AppBskyFeedDefs.PostView
rootPost: AppBskyFeedDefs.PostView
}): React.ReactNode => {
const queryClient = useQueryClient()
const {openComposer} = useComposerControls()
@@ -225,7 +225,7 @@ let FeedItemInner = ({
reason.by.did === currentAccount?.did
const threadgateRecord = AppBskyFeedThreadgate.isRecord(
rootPost?.threadgate?.record,
rootPost.threadgate?.record,
)
? rootPost.threadgate.record
: undefined