Skip to content

Commit 77cbf72

Browse files
author
Harsh Reddy
committed
Bug Fixes
1 parent aac3a0e commit 77cbf72

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packages/core/src/helpers/graphql.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ const createSplitLink = (token?: string): ApolloLink => {
127127
* @param token - Optional authentication token (defaults to READ_ONLY_TOKEN)
128128
* @returns Configured Apollo Client instance
129129
*/
130-
export const createApolloClient = (token?: string): ApolloClient<NormalizedCacheObject> => {
130+
export const createApolloClient = (token?: string) => {
131131
const link = createSplitLink(token);
132132

133133
return new ApolloClient({
@@ -163,7 +163,7 @@ export const createApolloClient = (token?: string): ApolloClient<NormalizedCache
163163
* Singleton Apollo Client instance
164164
* Can be reused across the application
165165
*/
166-
let apolloClientInstance: ApolloClient<NormalizedCacheObject> | null = null;
166+
let apolloClientInstance: ReturnType<typeof createApolloClient> | null = null;
167167

168168
/**
169169
* Get or create Apollo Client instance
@@ -175,7 +175,7 @@ let apolloClientInstance: ApolloClient<NormalizedCacheObject> | null = null;
175175
export const getApolloClient = (
176176
token?: string,
177177
forceNew = false
178-
): ApolloClient<NormalizedCacheObject> => {
178+
) => {
179179
if (!apolloClientInstance || forceNew) {
180180
apolloClientInstance = createApolloClient(token);
181181
}

0 commit comments

Comments
 (0)