fix(workflows-sdk): name for when/then step (#10459)
This commit is contained in:
@@ -65,7 +65,7 @@ export const completeCartWorkflow = createWorkflow(
|
||||
})
|
||||
|
||||
// If order ID does not exist, we are completing the cart for the first time
|
||||
const order = when({ orderId }, ({ orderId }) => {
|
||||
const order = when("create-order", { orderId }, ({ orderId }) => {
|
||||
return !orderId
|
||||
}).then(() => {
|
||||
const cart = useRemoteQueryStep({
|
||||
|
||||
@@ -70,9 +70,13 @@ export const listShippingOptionsForCartWorkflow = createWorkflow(
|
||||
}
|
||||
)
|
||||
|
||||
const customerGroupIds = when({ cart }, ({ cart }) => {
|
||||
return !!cart.id
|
||||
}).then(() => {
|
||||
const customerGroupIds = when(
|
||||
"get-customer-group",
|
||||
{ cart },
|
||||
({ cart }) => {
|
||||
return !!cart.id
|
||||
}
|
||||
).then(() => {
|
||||
const customerQuery = useQueryGraphStep({
|
||||
entity: "customer",
|
||||
filters: { id: cart.customer_id },
|
||||
|
||||
Reference in New Issue
Block a user