summaryrefslogtreecommitdiff
path: root/system/api/server.go
diff options
context:
space:
mode:
authorSteve Manuel <nilslice@gmail.com>2017-01-16 15:21:52 -0800
committerSteve Manuel <nilslice@gmail.com>2017-01-16 15:21:52 -0800
commita645a66ecd2d68cb6719cb22bdb91a0480be8659 (patch)
treeced3a7c2859656eb5eab696606075dcb7c6032a5 /system/api/server.go
parentd2647904359bc79090583a66197768eb7de462b3 (diff)
adding gzip compression to api endpoints
Diffstat (limited to 'system/api/server.go')
-rw-r--r--system/api/server.go4
1 files changed, 2 insertions, 2 deletions
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))
}