diff options
Diffstat (limited to 'vendor/github.com/spf13/afero/util.go')
-rw-r--r-- | vendor/github.com/spf13/afero/util.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/vendor/github.com/spf13/afero/util.go b/vendor/github.com/spf13/afero/util.go index 2f44e6a..4f253f4 100644 --- a/vendor/github.com/spf13/afero/util.go +++ b/vendor/github.com/spf13/afero/util.go @@ -20,7 +20,6 @@ import ( "bytes" "fmt" "io" - "log" "os" "path/filepath" "strings" @@ -46,7 +45,7 @@ func WriteReader(fs Fs, path string, r io.Reader) (err error) { err = fs.MkdirAll(ospath, 0777) // rwx, rw, r if err != nil { if err != os.ErrExist { - log.Panicln(err) + return err } } } @@ -157,7 +156,7 @@ func UnicodeSanitize(s string) string { return string(target) } -// Transform characters with accents into plan forms +// Transform characters with accents into plain forms. func NeuterAccents(s string) string { t := transform.Chain(norm.NFD, transform.RemoveFunc(isMn), norm.NFC) result, _, _ := transform.String(t, string(s)) |