feat: allow disabling file detections by reading header (#1175)

This commit is contained in:
WeidiDeng
2021-01-07 18:30:17 +08:00
committed by GitHub
parent 43e0d4a856
commit 6914063853
8 changed files with 104 additions and 85 deletions

View File

@@ -5,7 +5,7 @@ import (
"unicode/utf8"
)
func isBinary(content []byte, _ int) bool {
func isBinary(content []byte) bool {
maybeStr := string(content)
runeCnt := utf8.RuneCount(content)
runeIndex := 0