Skip to content

Commit

Permalink
fix(call-service): Fix merge context merge order
Browse files Browse the repository at this point in the history
  • Loading branch information
zachowj committed Jan 9, 2024
1 parent 05e519f commit e2f2ac8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/nodes/call-service/CallServiceController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,12 @@ export default class CallServiceController extends InputOutputController<
const flowVal = ctx.flow.get(this.node.config.mergeContext);
const globalVal = ctx.global.get(this.node.config.mergeContext);

if (this.#isValidContextData(flowVal)) {
contextData = flowVal;
if (this.#isValidContextData(globalVal)) {
contextData = globalVal;
}

if (this.#isValidContextData(globalVal)) {
contextData = { ...contextData, ...globalVal };
if (this.#isValidContextData(flowVal)) {
contextData = { ...contextData, ...flowVal };
}
}

Expand Down

0 comments on commit e2f2ac8

Please sign in to comment.