feature/IO-3000-messaging-sockets-migration2 - Handle some of the PR notes
Signed-off-by: Dave Richer <dave@imexsystems.ca>
This commit is contained in:
@@ -31,7 +31,7 @@ export function ChatPopupComponent({ chatVisible, selectedConversation, toggleCh
|
|||||||
const client = useApolloClient(); // Apollo Client instance for cache operations
|
const client = useApolloClient(); // Apollo Client instance for cache operations
|
||||||
|
|
||||||
// Lazy query for conversations
|
// Lazy query for conversations
|
||||||
const [getConversations, { loading, data, refetch, fetchMore }] = useLazyQuery(CONVERSATION_LIST_QUERY, {
|
const [getConversations, { loading, data, refetch }] = useLazyQuery(CONVERSATION_LIST_QUERY, {
|
||||||
fetchPolicy: "network-only",
|
fetchPolicy: "network-only",
|
||||||
nextFetchPolicy: "network-only",
|
nextFetchPolicy: "network-only",
|
||||||
skip: !chatVisible,
|
skip: !chatVisible,
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ export function* openChatByPhone({ payload }) {
|
|||||||
} = yield client.query({
|
} = yield client.query({
|
||||||
query: CONVERSATION_ID_BY_PHONE,
|
query: CONVERSATION_ID_BY_PHONE,
|
||||||
variables: { phone: p.number },
|
variables: { phone: p.number },
|
||||||
fetchPolicy: "no-cache"
|
fetchPolicy: "network-only"
|
||||||
});
|
});
|
||||||
|
|
||||||
if (conversations.length === 0) {
|
if (conversations.length === 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user