fix linter errors

This commit is contained in:
2026-01-05 11:06:41 +01:00
committed by T. von Dein
parent a02e521998
commit 541ead764c
2 changed files with 6 additions and 2 deletions

View File

@@ -199,7 +199,7 @@ func (conf *Config) WriteConfigFile() (string, error) {
cfgfile := filepath.Join(conf.GetConfigDir(), "config.toml") cfgfile := filepath.Join(conf.GetConfigDir(), "config.toml")
if FileExists(cfgfile) { if FileExists(cfgfile) {
return "", fmt.Errorf("config file %s already exists.", cfgfile) return "", fmt.Errorf("config file %s already exists", cfgfile)
} }
var kloader = koanf.New(".") var kloader = koanf.New(".")

View File

@@ -58,7 +58,11 @@ func Execute(output io.Writer) int {
return Die(err) return Die(err)
} }
fmt.Fprintln(output, msg) _, err = fmt.Fprintln(output, msg)
if err != nil {
return Die(fmt.Errorf("failed to print to output: %s", err))
}
return 0 return 0
} }