mirror of
https://github.com/nkanaev/yarr.git
synced 2025-09-13 18:00:05 +00:00
remove bom
This commit is contained in:
@@ -17,6 +17,7 @@ type processor func(r io.Reader) (*Feed, error)
|
||||
|
||||
func sniff(lookup string) (string, processor) {
|
||||
lookup = strings.TrimSpace(lookup)
|
||||
lookup = strings.TrimLeft(lookup, "\x00\xEF\xBB\xBF\xFE\xFF")
|
||||
switch lookup[0] {
|
||||
case '<':
|
||||
decoder := xmlDecoder(strings.NewReader(lookup))
|
||||
|
Reference in New Issue
Block a user