Added a notice to a comment for Handler() method.

This commit is contained in:
Alexander Andreev 2023-09-05 06:02:11 +04:00
parent b4163d2162
commit a23264b00f
Signed by: Arav
GPG Key ID: D22A817D95815393

View File

@ -212,6 +212,7 @@ func (rr *Router) ServeHTTP(w http.ResponseWriter, r *http.Request) {
}
// Handler registers a handler for provided pattern for a given HTTP method.
// Pattern must start with a slash (/) symbol.
func (rr *Router) Handler(method, pattern string, handler http.HandlerFunc) error {
path, err := newPath(pattern)
if err != nil {