We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7446950 commit bec368aCopy full SHA for bec368a
middleware/maybe.go
@@ -4,7 +4,7 @@ import "net/http"
4
5
// Maybe middleware will allow you to change the flow of the middleware stack execution depending on return
6
// value of maybeFn(request). This is useful for example if you'd like to skip a middleware handler if
7
-// a request does not satisfied the maybeFn logic.
+// a request does not satisfy the maybeFn logic.
8
func Maybe(mw func(http.Handler) http.Handler, maybeFn func(r *http.Request) bool) func(http.Handler) http.Handler {
9
return func(next http.Handler) http.Handler {
10
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
0 commit comments