diff --git a/flow/workflows/sync_flow.go b/flow/workflows/sync_flow.go index efdae0f1a8..6d2c9def50 100644 --- a/flow/workflows/sync_flow.go +++ b/flow/workflows/sync_flow.go @@ -179,7 +179,7 @@ func SyncFlowWorkflow( } }) - for ctx.Err() == nil && (syncErr || !syncDone || selector.HasPending()) { + for ctx.Err() == nil && ((!syncDone && !syncErr) || selector.HasPending()) { selector.Select(ctx) } if ctx.Err() != nil {