This commit is contained in:
Fabian Jakobs 2024-09-04 13:23:26 +02:00
parent 02745de237
commit 4c9bf79c76
No known key found for this signature in database
1 changed files with 2 additions and 1 deletions

View File

@ -319,7 +319,8 @@ func (r *renderer) persistToDisk() error {
_, err := os.Stat(path)
if err == nil {
return fmt.Errorf("failed to initialize template, one or more files already exist: %s", path)
} else if !errors.Is(err, fs.ErrNotExist) {
}
if !errors.Is(err, fs.ErrNotExist) {
return fmt.Errorf("error while verifying file %s does not already exist: %w", path, err)
}
}