mirror of
https://github.com/navidrome/navidrome.git
synced 2025-04-19 13:27:42 +03:00
Respect EnableLogRedacting config when pretty printing configuration
This commit is contained in:
parent
7b05c49215
commit
ead2095dd0
@ -117,8 +117,13 @@ func Load() {
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Print current configuration if log level is Debug
|
||||
if log.CurrentLevel() >= log.LevelDebug {
|
||||
fmt.Println(log.Redact(pretty.Sprintf("Loaded configuration from '%s': %# v", Server.ConfigFile, Server)))
|
||||
prettyConf := pretty.Sprintf("Loaded configuration from '%s': %# v", Server.ConfigFile, Server)
|
||||
if Server.EnableLogRedacting {
|
||||
prettyConf = log.Redact(prettyConf)
|
||||
}
|
||||
fmt.Println(prettyConf)
|
||||
}
|
||||
|
||||
// Call init hooks
|
||||
|
Loading…
x
Reference in New Issue
Block a user