aboutsummaryrefslogtreecommitdiff
path: root/strings.go
diff options
context:
space:
mode:
authorGravatar Aliaksandr Valialkin <valyala@gmail.com> 2017-05-17 17:10:29 +0300
committerGravatar Aliaksandr Valialkin <valyala@gmail.com> 2017-05-17 17:10:29 +0300
commitb154429ca951971beae8427b1a918ebce58f64af (patch)
tree9a9716e3dece82941b1c35381f0dd67d8197dc19 /strings.go
parentDo not compress responses with sizes smaller than 200 bytes (diff)
downloadfasthttp-b154429ca951971beae8427b1a918ebce58f64af.tar.gz
fasthttp-b154429ca951971beae8427b1a918ebce58f64af.tar.bz2
fasthttp-b154429ca951971beae8427b1a918ebce58f64af.zip
Compress responses only if their content-type starts with text/ or application/
Diffstat (limited to 'strings.go')
-rw-r--r--strings.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/strings.go b/strings.go
index 656df1c..ebfa3ed 100644
--- a/strings.go
+++ b/strings.go
@@ -68,4 +68,6 @@ var (
strMultipartFormData = []byte("multipart/form-data")
strBoundary = []byte("boundary")
strBytes = []byte("bytes")
+ strTextSlash = []byte("text/")
+ strApplicationSlash = []byte("application/")
)