diff options
author | tjpcc <tjp@ctrl-c.club> | 2023-01-18 22:10:29 -0700 |
---|---|---|
committer | tjpcc <tjp@ctrl-c.club> | 2023-01-18 22:10:29 -0700 |
commit | f569df6eade1373dee7116ceac977636bdfc8edc (patch) | |
tree | 11cb486062fbbf5356bb0f7ca749af89ae3754ae /handler.go | |
parent | 6586db782ea6dcb5f2eb191a690ec7e7df51161f (diff) |
bugfix and some docs cleanup
Diffstat (limited to 'handler.go')
-rw-r--r-- | handler.go | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -29,11 +29,11 @@ func FallthroughHandler(handlers ...Handler) Handler { } } -// Filter builds a middleware which only calls the wrapped under a condition. +// Filter builds a middleware which only calls the wrapped Handler under a condition. // -// When the condition function returns false it instead invokes the -// test-failure handler. The failure handler may also be nil, in which case -// the final handler will return a nil response whenever the condition fails. +// When the condition function returns false it instead invokes the test-failure +// handler. The failure handler may also be nil, in which case the final handler will +// return a nil response whenever the condition fails. func Filter( condition func(context.Context, *Request) bool, failure Handler, |