Skip to content

Commit d3f0286

Browse files
joeybloggsjoeybloggs
authored andcommitted
Add comment about ParseForm and ParseMultipartForm
1 parent 372b4df commit d3f0286

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,10 @@ l.RegisterContext(ContextFunc)
193193

194194
// Register custom handler type, see [util.go](https://github.com/go-playground/lars/blob/master/util.go#L62) for example handler creation
195195
l.RegisterCustomHandler(interface{}, CustomHandlerFunc)
196+
197+
// Context has 2 methods of which you should be aware of ParseForm and ParseMulipartForm, they just call the default http functions but
198+
// provide one more additional feature, they copy the URL params to the request Forms variables, just like Query parameters would have been.
199+
// The functions are for convenience and are totally optional.
196200
```
197201

198202
Middleware

doc.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,5 +156,9 @@ Misc
156156
157157
// Register custom handler type, see util.go https://github.com/go-playground/lars/blob/master/util.go#L62 for example handler creation
158158
l.RegisterCustomHandler(interface{}, CustomHandlerFunc)
159+
160+
// Context has 2 methods of which you should be aware of ParseForm and ParseMulipartForm, they just call the default http functions but
161+
// provide one more additional feature, they copy the URL params to the request Forms variables, just like Query parameters would have been.
162+
// The functions are for convenience and are totally optional.
159163
*/
160164
package lars

0 commit comments

Comments
 (0)