From 63a3716a8ae5394e312a3fdf6aea15e4d1e9c5d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Rozynek?= Date: Mon, 15 Feb 2021 15:50:51 +0100 Subject: [PATCH] Cleanup references to NewWith --- README.md | 2 +- emf/logger.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0b7dc70..51480fe 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ defer m.Log() Customizing the logger: ``` -emf.NewWith( +emf.New( emf.WithWriter(os.Stderr), // Log to stderr. emf.WithTimestamp(time.Now().Add(-time.Hour)), // Record past metrics. ) diff --git a/emf/logger.go b/emf/logger.go index 96eb85b..fe197f1 100644 --- a/emf/logger.go +++ b/emf/logger.go @@ -44,7 +44,7 @@ func WithTimestamp(t time.Time) LoggerOption { // New creates logger with reasonable defaults for Lambda functions: // - Prints to os.Stdout. // - Context based on Lambda environment variables. -// - Timestamp set to the time when NewWith was called. +// - Timestamp set to the time when New was called. // Specify LoggerOptions to customize the logger. func New(opts ...LoggerOption) *Logger { values := make(map[string]interface{})