From 0216f85935fe5b96d6c4c3eb68156ba6a1629f6a Mon Sep 17 00:00:00 2001 From: Aditya <60684641+0x0elliot@users.noreply.github.com> Date: Tue, 5 Sep 2023 20:05:07 +0530 Subject: [PATCH] fix: removing unnecessary images in db too --- db-connector.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/db-connector.go b/db-connector.go index f456caa..dd7e94b 100755 --- a/db-connector.go +++ b/db-connector.go @@ -1192,6 +1192,9 @@ func sanitizeString(input string) string { } func Fixexecution(ctx context.Context, workflowExecution WorkflowExecution) WorkflowExecution { + workflowExecution.Workflow.Image = "" + + // Make sure to not having missing items in the execution lastexecVar := map[string]ActionResult{} for _, action := range workflowExecution.Workflow.Actions { @@ -1260,11 +1263,16 @@ func Fixexecution(ctx context.Context, workflowExecution WorkflowExecution) Work // Don't forget any!! extra := 0 - for _, trigger := range workflowExecution.Workflow.Triggers { + for triggerIndex, trigger := range workflowExecution.Workflow.Triggers { if trigger.TriggerType != "SUBFLOW" && trigger.TriggerType != "USERINPUT" { continue } + trigger.LargeImage = "" + trigger.SmallImage = "" + + workflowExecution.Workflow.Triggers[triggerIndex] = trigger + extra += 1 found := false