From 7693502aaa65b2a62e4aea005d2ee21250fa3dc4 Mon Sep 17 00:00:00 2001 From: JessonChan Date: Tue, 12 Mar 2019 13:20:13 +0800 Subject: [PATCH] logAdapter is more readable --- logs/log.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/logs/log.go b/logs/log.go index 3bf9c5f4..49f3794f 100644 --- a/logs/log.go +++ b/logs/log.go @@ -187,12 +187,12 @@ func (bl *BeeLogger) setLogger(adapterName string, configs ...string) error { } } - log, ok := adapters[adapterName] + logAdapter, ok := adapters[adapterName] if !ok { return fmt.Errorf("logs: unknown adaptername %q (forgotten Register?)", adapterName) } - lg := log() + lg := logAdapter() err := lg.Init(config) if err != nil { fmt.Fprintln(os.Stderr, "logs.BeeLogger.SetLogger: "+err.Error())