diff --git a/ext/dispatcher.go b/ext/dispatcher.go index 29655f1..e427a6a 100644 --- a/ext/dispatcher.go +++ b/ext/dispatcher.go @@ -5,7 +5,6 @@ import ( "errors" "fmt" "log/slog" - "os" "runtime/debug" "strings" "sync" @@ -128,7 +127,7 @@ func NewDispatcher(opts *DispatcherOpts) *Dispatcher { var errHandler DispatcherErrorHandler var panicHandler DispatcherPanicHandler var unhandledErrFunc ErrorFunc - logger := slog.New(slog.NewTextHandler(os.Stderr, nil)) + logger := slog.Default() maxRoutines := DefaultMaxRoutines processor := Processor(BaseProcessor{}) diff --git a/ext/updater.go b/ext/updater.go index 6456a86..4812f9b 100644 --- a/ext/updater.go +++ b/ext/updater.go @@ -8,7 +8,6 @@ import ( "log/slog" "net" "net/http" - "os" "strconv" "strings" "time" @@ -62,7 +61,7 @@ type UpdaterOpts struct { // NewUpdater Creates a new Updater, as well as a Dispatcher and any optional updater configurations (via UpdaterOpts). func NewUpdater(dispatcher UpdateDispatcher, opts *UpdaterOpts) *Updater { var unhandledErrFunc ErrorFunc - logger := slog.New(slog.NewTextHandler(os.Stderr, nil)) + logger := slog.Default() if opts != nil { unhandledErrFunc = opts.UnhandledErrFunc