events/errors.go

17 lines
279 B
Go
Raw Normal View History

package events
import "fmt"
type HandlerError struct {
topic string
errs []error
}
func (h HandlerError) Error() string {
return fmt.Sprintf("caught %d errors from topic '%v': %v", len(h.errs), h.topic, h.errs)
}
func (h HandlerError) Unwrap() []error {
return h.errs
}