From 7c96c8759086659b2b58761a1aa026319593a475 Mon Sep 17 00:00:00 2001 From: Marcel Heers Date: Mon, 15 Mar 2021 15:50:19 +0100 Subject: [PATCH] lint --- files/file.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/files/file.go b/files/file.go index abd3766c..e104c54b 100644 --- a/files/file.go +++ b/files/file.go @@ -167,7 +167,8 @@ func (i *FileInfo) detectType(modify, saveContent, readHeader bool) error { case strings.HasPrefix(mimetype, "image"): i.Type = "image" return nil - case (strings.HasPrefix(mimetype, "text") || strings.HasSuffix(mimetype, "json") || (len(buffer) > 0 && !isBinary(buffer))) && i.Size <= 10*1024*1024: // 10 MB + case (strings.HasPrefix(mimetype, "text") || strings.HasSuffix(mimetype, "json") || + (len(buffer) > 0 && !isBinary(buffer))) && i.Size <= 10*1024*1024: // 10 MB i.Type = "text" if !modify {