Corrected error messages for CliArgs

This commit is contained in:
Jason Streifling 2024-03-29 09:48:03 +01:00
parent 9408ce99e3
commit 1ee94efe9d

View File

@ -27,19 +27,19 @@ func HandleCliArgs() (*CliArgs, error) {
cliArgs.KeyFile, err = filepath.Abs(*keyFile) cliArgs.KeyFile, err = filepath.Abs(*keyFile)
if err != nil { if err != nil {
return nil, fmt.Errorf("error finding KeyFile: %v", err) return nil, fmt.Errorf("error finding absolute path for KeyFile: %v", err)
} }
cliArgs.LogFile, err = filepath.Abs(*logFile) cliArgs.LogFile, err = filepath.Abs(*logFile)
if err != nil { if err != nil {
return nil, fmt.Errorf("error finding LogFile: %v", err) return nil, fmt.Errorf("error finding absolute path for LogFile: %v", err)
} }
cliArgs.PicsDir, err = filepath.Abs(*picsDir) cliArgs.PicsDir, err = filepath.Abs(*picsDir)
if err != nil { if err != nil {
return nil, fmt.Errorf("error finding PicsDir: %v", err) return nil, fmt.Errorf("error finding absolute path for PicsDir: %v", err)
} }
cliArgs.WebDir, err = filepath.Abs(*webDir) cliArgs.WebDir, err = filepath.Abs(*webDir)
if err != nil { if err != nil {
return nil, fmt.Errorf("error finding WebDir: %v", err) return nil, fmt.Errorf("error finding absolute path for WebDir: %v", err)
} }
return cliArgs, nil return cliArgs, nil