Skip to content

Commit

Permalink
add escape for no after effects
Browse files Browse the repository at this point in the history
  • Loading branch information
KyleSmith19091 committed Nov 11, 2024
1 parent 5236c18 commit 1b68c79
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion etl/pipeline/pipelineState.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,11 @@ func (p *PipelineState) RegisterAfterEffect(afterEffect AfterEffect) {
}

func (p *PipelineState) RunAfterEffects(ctx context.Context) error {
errGroup := new(errgroup.Group)
if len(p.afterEffects) == 0 {
return nil
}

errGroup := new(errgroup.Group)
for _, afterEffect := range p.afterEffects {
errGroup.Go(func() error {
return afterEffect(ctx)
Expand Down

0 comments on commit 1b68c79

Please sign in to comment.