mirror of
https://github.com/flavioribeiro/donut.git
synced 2025-10-17 04:20:36 +08:00
leverage error handling as a middleware
This commit is contained in:
@@ -16,7 +16,7 @@ type SRTController struct {
|
||||
|
||||
func NewSRTController(c *entities.Config, l *zap.Logger, lc fx.Lifecycle) (*SRTController, error) {
|
||||
// Handle logs
|
||||
astisrt.SetLogLevel(astisrt.LogLevel(astisrt.LogLevelError))
|
||||
astisrt.SetLogLevel(astisrt.LogLevel(astisrt.LogLevelNotice))
|
||||
astisrt.SetLogHandler(func(ll astisrt.LogLevel, file, area, msg string, line int) {
|
||||
l.Sugar().Infow("SRT",
|
||||
"ll", ll,
|
||||
|
Reference in New Issue
Block a user