From a645a66ecd2d68cb6719cb22bdb91a0480be8659 Mon Sep 17 00:00:00 2001 From: Steve Manuel Date: Mon, 16 Jan 2017 15:21:52 -0800 Subject: adding gzip compression to api endpoints --- system/api/server.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'system/api/server.go') diff --git a/system/api/server.go b/system/api/server.go index 0bdc48a..8e103c4 100644 --- a/system/api/server.go +++ b/system/api/server.go @@ -4,9 +4,9 @@ import "net/http" // Run adds Handlers to default http listener for API func Run() { - http.HandleFunc("/api/contents", Record(CORS(contentsHandler))) + http.HandleFunc("/api/contents", Record(CORS(Gzip(contentsHandler)))) - http.HandleFunc("/api/content", Record(CORS(contentHandler))) + http.HandleFunc("/api/content", Record(CORS(Gzip(contentHandler)))) http.HandleFunc("/api/content/external", Record(externalContentHandler)) } -- cgit v1.2.3