Skip to content

Commit

Permalink
Possibly fix traveling comments
Browse files Browse the repository at this point in the history
  • Loading branch information
IanPhilips committed Oct 16, 2024
1 parent 1c487ab commit 669cb15
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions web/components/contract/contract-tabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -201,9 +201,14 @@ export const CommentsTabContent = memo(function CommentsTabContent(props: {
const user = useUser()

// Load all comments once
const { data: fetchedComments } = useAPIGetter('comments', {
contractId: playContract.id,
})
const { data: fetchedComments } = useAPIGetter(
'comments',
{
contractId: playContract.id,
},
undefined,
'comments-' + playContract.id
)

// Listen for new comments
const newComments = useSubscribeNewComments(playContract.id)
Expand Down

0 comments on commit 669cb15

Please sign in to comment.