diff --git a/src/modules/Elsa.Workflows.Core/Activities/Complete.cs b/src/modules/Elsa.Workflows.Core/Activities/Complete.cs index 90ad5dd42..23b0c15bc 100644 --- a/src/modules/Elsa.Workflows.Core/Activities/Complete.cs +++ b/src/modules/Elsa.Workflows.Core/Activities/Complete.cs @@ -1,4 +1,5 @@ using System.ComponentModel; +using System.Text.Json.Serialization; using Elsa.Expressions.Models; using Elsa.Workflows.Core.Activities.Flowchart.Models; using Elsa.Workflows.Core.Attributes; @@ -13,6 +14,12 @@ namespace Elsa.Workflows.Core.Activities; [Activity("Elsa", "Primitives", "Signals the current composite activity to complete itself as a whole.")] public class Complete : Activity { + /// + [JsonConstructor] + public Complete() + { + } + /// public Complete(params string[] outcomes) : this(new Input>(outcomes)) { @@ -35,7 +42,7 @@ public class Complete : Activity /// The outcome or set of outcomes to complete this activity with. /// [Description("The outcome or set of outcomes to complete this activity with.")] - public Input> Outcomes { get; set; } + public Input> Outcomes { get; set; } = new(new List()); /// protected override async ValueTask ExecuteAsync(ActivityExecutionContext context)