diff --git a/logtail/logtail.go b/logtail/logtail.go index 1991d11bf..4a132363f 100644 --- a/logtail/logtail.go +++ b/logtail/logtail.go @@ -143,9 +143,6 @@ type logger struct { } func (l *logger) Shutdown(ctx context.Context) error { - if ctx == nil { - ctx = context.Background() - } done := make(chan struct{}) go func() { select { @@ -168,7 +165,7 @@ func (l *logger) Shutdown(ctx context.Context) error { } func (l *logger) Close() { - l.Shutdown(nil) + l.Shutdown(context.Background()) } func (l *logger) drainPending() (res []byte) {