MCPcopy
hub / github.com/perkeep/perkeep / serveHTTP

Method serveHTTP

app/scanningcabinet/handler.go:174–181  ·  view source on GitHub ↗
(w http.ResponseWriter, r *http.Request)

Source from the content-addressed store, hash-verified

172}
173
174func (h *handler) serveHTTP(w http.ResponseWriter, r *http.Request) {
175 if h.mux == nil {
176 http.Error(w, "handler not properly initialized", http.StatusInternalServerError)
177 return
178 }
179 r.URL.Path = strings.Replace(r.URL.Path, app.PathPrefix(r), "/", 1)
180 h.mux.ServeHTTP(w, r)
181}
182
183type rootData struct {
184 BaseURL string

Callers 1

ServeHTTPMethod · 0.95

Calls 3

PathPrefixFunction · 0.92
ErrorMethod · 0.45
ServeHTTPMethod · 0.45

Tested by

no test coverage detected