MCPcopy Index your code
hub / github.com/dnote/dnote / WebMw

Function WebMw

pkg/server/middleware/middleware.go:47–53  ·  view source on GitHub ↗

WebMw is the middleware for the web

(h http.Handler, app *app.App, rateLimit bool)

Source from the content-addressed store, hash-verified

45
46// WebMw is the middleware for the web
47func WebMw(h http.Handler, app *app.App, rateLimit bool) http.Handler {
48 ret := h
49
50 ret = ApplyLimit(ret.ServeHTTP, rateLimit)
51
52 return ret
53}
54
55// APIMw is the middleware for the API
56func APIMw(h http.Handler, app *app.App, rateLimit bool) http.Handler {

Callers

nothing calls this directly

Calls 1

ApplyLimitFunction · 0.85

Tested by

no test coverage detected