fix(core-flows): useQueryGraph util return type (#12962)
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
"@medusajs/core-flows": patch
|
||||||
|
---
|
||||||
|
|
||||||
|
fix(core-flows): useQueryGraph util return type
|
||||||
@@ -7,9 +7,10 @@ import {
|
|||||||
import { createStep, StepFunction, StepResponse } from "@medusajs/workflows-sdk"
|
import { createStep, StepFunction, StepResponse } from "@medusajs/workflows-sdk"
|
||||||
import { ContainerRegistrationKeys } from "@medusajs/utils"
|
import { ContainerRegistrationKeys } from "@medusajs/utils"
|
||||||
|
|
||||||
export type UseQueryGraphStepInput<TEntry extends string> = RemoteQueryInput<TEntry> & {
|
export type UseQueryGraphStepInput<TEntry extends string> =
|
||||||
options?: RemoteJoinerOptions
|
RemoteQueryInput<TEntry> & {
|
||||||
}
|
options?: RemoteJoinerOptions
|
||||||
|
}
|
||||||
|
|
||||||
const useQueryGraphStepId = "use-query-graph-step"
|
const useQueryGraphStepId = "use-query-graph-step"
|
||||||
|
|
||||||
@@ -101,5 +102,7 @@ const step = createStep(
|
|||||||
*/
|
*/
|
||||||
export const useQueryGraphStep = <const TEntry extends string>(
|
export const useQueryGraphStep = <const TEntry extends string>(
|
||||||
input: UseQueryGraphStepInput<TEntry>
|
input: UseQueryGraphStepInput<TEntry>
|
||||||
): ReturnType<StepFunction<UseQueryGraphStepInput<TEntry>, GraphResultSet<TEntry>>> =>
|
): ReturnType<StepFunction<any, GraphResultSet<TEntry>>> =>
|
||||||
step(input as any) as unknown as ReturnType<StepFunction<UseQueryGraphStepInput<TEntry>, GraphResultSet<TEntry>>>
|
step(input as any) as unknown as ReturnType<
|
||||||
|
StepFunction<any, GraphResultSet<TEntry>>
|
||||||
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user