Skip to content

Commit

Permalink
Forward action output to sinks
Browse files Browse the repository at this point in the history
  • Loading branch information
mszostok committed Jan 10, 2024
1 parent 28ef1c7 commit 6eedab3
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion internal/source/dispatcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,16 @@ func (d *Dispatcher) dispatchMsg(ctx context.Context, event source.Event, dispat
defer analytics.ReportPanicIfOccurs(d.log, d.reporter)
err := n.SendMessage(ctx, genericMsg, sources)
if err != nil {
d.log.Errorf("while sending action result message: %s", err.Error())
d.log.Errorf("while sending action result to %q bot: %s", n.IntegrationName(), err.Error())
}
}(n)
}

for _, n := range d.getSinkNotifiers(dispatch) {
go func(n notifier.Sink) {
err := n.SendEvent(ctx, genericMsg, sources)
if err != nil {
d.log.Errorf("while sending action result to %q sink: %s", n.IntegrationName(), err.Error())
}
}(n)
}
Expand Down

0 comments on commit 6eedab3

Please sign in to comment.