Skip to content

Commit

Permalink
Add workflow result variable to context scope
Browse files Browse the repository at this point in the history
In the ExpressionExecutionContextExtensions module, an additional check and yield operation has been implemented. This allows the inclusion of the workflow result variable, if it exists, to the current context scope.
  • Loading branch information
sfmskywalker committed Dec 29, 2023
1 parent d978151 commit c33801d
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,12 @@ public static IEnumerable<Variable> EnumerateVariablesInScope(this ExpressionExe

currentScope = currentScope.ParentContext;
}

if (context.TryGetWorkflowExecutionContext(out var workflowExecutionContext))
{
if (workflowExecutionContext.Workflow.ResultVariable != null)
yield return workflowExecutionContext.Workflow.ResultVariable;
}
}

/// <summary>
Expand Down

0 comments on commit c33801d

Please sign in to comment.