fix(config): log level change causes panic (#1296)

This commit is contained in:
ze0s 2023-12-02 17:23:08 +01:00 committed by GitHub
parent 365055fbe1
commit 17e97201fd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -171,7 +171,9 @@ type AppConfig struct {
}
func New(configPath string, version string) *AppConfig {
c := &AppConfig{}
c := &AppConfig{
m: new(sync.Mutex),
}
c.defaults()
c.Config.Version = version
c.Config.ConfigPath = configPath