fix react query error
This commit is contained in:
@@ -204,7 +204,7 @@ function Feed() {
|
||||
}, [params])
|
||||
const feedUri = params.type === 'feedgen' ? params.uri : undefined
|
||||
const {data: feedInfo} = useFeedInfo(feedUri)
|
||||
const feedFeedback = useFeedFeedback(feedInfo, hasSession)
|
||||
const feedFeedback = useFeedFeedback(feedInfo ?? undefined, hasSession)
|
||||
const {data, error, hasNextPage, isFetchingNextPage, fetchNextPage} =
|
||||
usePostFeedQuery(
|
||||
feedDesc,
|
||||
|
||||
@@ -637,7 +637,7 @@ export function useFeedInfo(feedUri: string | undefined) {
|
||||
queryKey: [feedInfoQueryKeyRoot, feedUri],
|
||||
queryFn: async () => {
|
||||
if (!feedUri) {
|
||||
return undefined
|
||||
return null
|
||||
}
|
||||
|
||||
const res = await agent.app.bsky.feed.getFeedGenerator({
|
||||
|
||||
Reference in New Issue
Block a user