agent: ensure all HTTP Server methods are pointer receivers. (#15250)

This commit is contained in:
James Rasell
2022-11-15 16:31:44 +01:00
committed by GitHub
parent b55ab6318e
commit a3f3018227

View File

@@ -347,7 +347,7 @@ func (s *HTTPServer) ResolveToken(req *http.Request) (*acl.ACL, error) {
}
// registerHandlers is used to attach our handlers to the mux
func (s HTTPServer) registerHandlers(enableDebug bool) {
func (s *HTTPServer) registerHandlers(enableDebug bool) {
s.mux.HandleFunc("/v1/jobs", s.wrap(s.JobsRequest))
s.mux.HandleFunc("/v1/jobs/parse", s.wrap(s.JobsParseRequest))
s.mux.HandleFunc("/v1/job/", s.wrap(s.JobSpecificRequest))