Skip to content
Browse files

doc/articles/wiki: use correct variable name in closures guide

Fixes non-existent variable TitleValidator to be validPath in
the closures, functions literal section.

Fixes #36779

Change-Id: I59762c358c3e00d1cc03d9d1e2aace03f145321d
GitHub-Last-Rev: a5e9b17
GitHub-Pull-Request: #36783
Reviewed-by: Emmanuel Odeke <>
  • Loading branch information
HowJMay authored and odeke-em committed Mar 20, 2020
1 parent 635a830 commit 9d468f482f20f886d3c7d66c60e1ce0acbaaad44
Showing with 1 addition and 1 deletion.
  1. +1 −1 doc/articles/wiki/index.html
@@ -674,7 +674,7 @@ <h2>Introducing Function Literals and Closures</h2>
an <code>http.ResponseWriter</code> and <code>http.Request</code> (in other
words, an <code>http.HandlerFunc</code>).
The closure extracts the <code>title</code> from the request path, and
validates it with the <code>TitleValidator</code> regexp. If the
validates it with the <code>validPath</code> regexp. If the
<code>title</code> is invalid, an error will be written to the
<code>ResponseWriter</code> using the <code>http.NotFound</code> function.
If the <code>title</code> is valid, the enclosed handler function

0 comments on commit 9d468f4

Please sign in to comment.
You can’t perform that action at this time.