We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f4a97fa commit 0a1308dCopy full SHA for 0a1308d
1 file changed
packages/solid-query/src/createBaseQuery.ts
@@ -64,8 +64,9 @@ export function createBaseQuery<
64
return observer.subscribe((result) => {
65
notifyManager.batchCalls(() => {
66
const query = observer.getCurrentQuery()
67
+ const { refetch, ...rest } = unwrap(result)
68
const unwrappedResult = {
- ...unwrap(result),
69
+ ...rest,
70
71
// hydrate() expects a QueryState object, which is similar but not
72
// quite the same as a QueryObserverResult object. Thus, for now, we're
@@ -84,7 +85,9 @@ export function createBaseQuery<
84
85
reject(unwrappedResult.error)
86
}
87
if (unwrappedResult.isSuccess) {
- resolve(unwrappedResult)
88
+ // Use of any here is fine
89
+ // We cannot include refetch since it is not serializable
90
+ resolve(unwrappedResult as any)
91
92
})()
93
})
0 commit comments