feat: [GODT-360] detect charset embedded in html and xml

This commit is contained in:
James Houlahan
2020-05-28 12:36:42 +02:00
parent 84d344cb0a
commit 9e633400b0
8 changed files with 65 additions and 48 deletions

View File

@ -174,7 +174,7 @@ func convertHexToUTF(charset, value string) (string, error) {
if err != nil {
return "", err
}
utf8, err := DecodeCharset(raw, map[string]string{"charset": charset})
utf8, err := DecodeCharset(raw, "text/plain; charset="+charset)
return "utf-8''" + percentHexEscape(utf8), err
}