MCPcopy
hub / github.com/usefathom/fathom / HandlerFunc

Function HandlerFunc

pkg/api/http.go:26–28  ·  view source on GitHub ↗

HandlerFunc takes a custom Handler func and converts it to http.HandlerFunc

(fn Handler)

Source from the content-addressed store, hash-verified

24
25// HandlerFunc takes a custom Handler func and converts it to http.HandlerFunc
26func HandlerFunc(fn Handler) http.HandlerFunc {
27 return http.HandlerFunc(Handler(fn).ServeHTTP)
28}
29
30// HandleError handles errors
31func HandleError(w http.ResponseWriter, r *http.Request, err error) {

Callers 3

serveFileHandlerFunction · 0.85
NotFoundHandlerFunction · 0.85
RoutesMethod · 0.85

Calls 1

HandlerFuncType · 0.85

Tested by

no test coverage detected