mirror of
https://github.com/hexastack/hexabot
synced 2025-06-26 18:27:28 +00:00
fix: update cache for new subscribers to use unfiltered query parameters
This commit is contained in:
parent
98d79488a9
commit
208ecbb5b8
@ -73,8 +73,9 @@ export const useInfiniteLiveSubscribers = (props: {
|
||||
if (event.op === "newSubscriber") {
|
||||
const { result } = normalizeAndCache(event.profile);
|
||||
|
||||
// Only update the unfiltered (all-subscribers) cache
|
||||
queryClient.setQueryData(
|
||||
[QueryType.infinite, EntityType.SUBSCRIBER, params],
|
||||
[QueryType.infinite, EntityType.SUBSCRIBER, { where: {} }],
|
||||
(oldData) => {
|
||||
if (oldData) {
|
||||
const data = oldData as InfiniteData<string[]>;
|
||||
|
Loading…
Reference in New Issue
Block a user