fix(logging): fixed default log level filter option not taking effect, fixex #6978

This commit is contained in:
Torkel Ödegaard 2016-12-15 13:54:47 +01:00
parent f9fba0e935
commit 94962b4193

View File

@ -122,7 +122,7 @@ var logLevels = map[string]log15.Lvl{
}
func getLogLevelFromConfig(key string, defaultName string, cfg *ini.File) (string, log15.Lvl) {
levelName := cfg.Section(key).Key("level").MustString("info")
levelName := cfg.Section(key).Key("level").MustString(defaultName)
levelName = strings.ToLower(levelName)
level := getLogLevelFromString(levelName)
return levelName, level