fix lint
This commit is contained in:
parent
cf63c9711f
commit
f411354cd5
1 changed files with 15 additions and 3 deletions
|
|
@ -1016,7 +1016,11 @@ func LoadConfig(path string) (*Config, error) {
|
||||||
// Legacy config (no version field)
|
// Legacy config (no version field)
|
||||||
v, e := loadConfigV0(data)
|
v, e := loadConfigV0(data)
|
||||||
if e != nil {
|
if e != nil {
|
||||||
logger.ErrorCF("config", formatDiagnosticLogMessage("Failed to load legacy config", e), map[string]any{"path": path})
|
logger.ErrorCF(
|
||||||
|
"config",
|
||||||
|
formatDiagnosticLogMessage("Failed to load legacy config", e),
|
||||||
|
map[string]any{"path": path},
|
||||||
|
)
|
||||||
return nil, e
|
return nil, e
|
||||||
}
|
}
|
||||||
cfg, e = v.Migrate()
|
cfg, e = v.Migrate()
|
||||||
|
|
@ -1055,7 +1059,11 @@ func LoadConfig(path string) (*Config, error) {
|
||||||
)
|
)
|
||||||
cfg, err = loadConfig(data)
|
cfg, err = loadConfig(data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.ErrorCF("config", formatDiagnosticLogMessage("Failed to load config", err), map[string]any{"path": path})
|
logger.ErrorCF(
|
||||||
|
"config",
|
||||||
|
formatDiagnosticLogMessage("Failed to load config", err),
|
||||||
|
map[string]any{"path": path},
|
||||||
|
)
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
secPath := securityPath(path)
|
secPath := securityPath(path)
|
||||||
|
|
@ -1090,7 +1098,11 @@ func LoadConfig(path string) (*Config, error) {
|
||||||
// Current version
|
// Current version
|
||||||
cfg, err = loadConfig(data)
|
cfg, err = loadConfig(data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.ErrorCF("config", formatDiagnosticLogMessage("Failed to load config", err), map[string]any{"path": path})
|
logger.ErrorCF(
|
||||||
|
"config",
|
||||||
|
formatDiagnosticLogMessage("Failed to load config", err),
|
||||||
|
map[string]any{"path": path},
|
||||||
|
)
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
// Load security configuration
|
// Load security configuration
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue