diff --git a/http_utility.go b/http_utility.go index 9896b87..c187b47 100644 --- a/http_utility.go +++ b/http_utility.go @@ -54,7 +54,8 @@ func UnauthorizedResponse(w http.ResponseWriter, req *http.Request) { } // TODO: Check for content type -// Sets common headers, checks for token validity and performs access control. +// WrapHandler sets common headers, checks for token validity and performs access control. +// If authentication passes it calls the handlerFunc. func WrapHandler(handlerFunc http.HandlerFunc, auth bool) http.HandlerFunc { return func(w http.ResponseWriter, req *http.Request) { w.Header().Set("Access-Control-Allow-Origin", "*")