diff options
Diffstat (limited to 'modules/template/template.go')
-rw-r--r-- | modules/template/template.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/modules/template/template.go b/modules/template/template.go index 9d63452d..cc670a65 100644 --- a/modules/template/template.go +++ b/modules/template/template.go @@ -127,11 +127,7 @@ func Sha1(str string) string { } func ToUtf8WithErr(content []byte) (error, string) { - charsetLabel, err := base.DetectEncoding(content) - if err != nil { - return err, "" - } - + charsetLabel := base.DetectEncoding(content) if charsetLabel == "UTF-8" { return nil, string(content) } |