From 4ebb553a500ec1b00691e3459081f0eca111bd85 Mon Sep 17 00:00:00 2001 From: Minh Doan Date: Tue, 8 Jan 2019 15:31:03 -0800 Subject: [PATCH] add singleton for logging --- internal/utils/singleton.go | 1 + 1 file changed, 1 insertion(+) diff --git a/internal/utils/singleton.go b/internal/utils/singleton.go index c67da712f..a37a84771 100644 --- a/internal/utils/singleton.go +++ b/internal/utils/singleton.go @@ -34,6 +34,7 @@ func (s *UniqueValidatorID) GetUniqueID() uint32 { return atomic.AddUint32(&s.uniqueID, 1) } +// GetLogInstance returns logging singleton. func GetLogInstance() log.Logger { onceForLog.Do(func() { logInstance = log.New()