4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-09-11 01:52:30 +00:00

Update dependencies (#1521)

This commit is contained in:
Wim
2021-06-16 21:00:49 +02:00
committed by GitHub
parent dedc1c45a1
commit fb5a84212c
243 changed files with 12622 additions and 14260 deletions

View File

@@ -132,11 +132,12 @@ func (l *Loader) LoadURL(url string) (*Properties, error) {
}
ct := resp.Header.Get("Content-Type")
ct = strings.Join(strings.Fields(ct), "")
var enc Encoding
switch strings.ToLower(ct) {
case "text/plain", "text/plain; charset=iso-8859-1", "text/plain; charset=latin1":
case "text/plain", "text/plain;charset=iso-8859-1", "text/plain;charset=latin1":
enc = ISO_8859_1
case "", "text/plain; charset=utf-8":
case "", "text/plain;charset=utf-8":
enc = UTF8
default:
return nil, fmt.Errorf("properties: invalid content type %s", ct)