feat: add stop reason

This commit is contained in:
langhuihui
2023-08-06 14:31:02 +08:00
parent 18137dfe8f
commit 080dc3a808
3 changed files with 58 additions and 62 deletions

View File

@@ -81,7 +81,7 @@ func (sub *HDLSubscriber) OnEvent(event any) {
}
}
if _, err := v.WriteTo(sub); err != nil {
sub.Stop()
sub.Stop(zap.Error(err))
// } else {
// println(time.Since(t)/time.Millisecond, s)
}