MCPcopy Create free account
hub / github.com/TheThingsNetwork/lorawan-stack / SetPathTemplate

Function SetPathTemplate

pkg/ratelimit/resource_util_test.go:20–24  ·  view source on GitHub ↗

SetPathTemplate sets the path template function for HTTP rate limiting.

(f func(*http.Request) (string, bool))

Source from the content-addressed store, hash-verified

18
19// SetPathTemplate sets the path template function for HTTP rate limiting.
20func SetPathTemplate(f func(*http.Request) (string, bool)) func() {
21 old := pathTemplate
22 pathTemplate = f
23 return func() { pathTemplate = old }
24}

Callers 1

TestHTTPFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected