github.com/emicklei/go-restful CWE-285: Improper Authorization
https://security.snyk.io/vuln/SNYK-GOLANG-GITHUBCOMEMICKLEIGORESTFUL-2435653 Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
This commit is contained in:
8
vendor/github.com/emicklei/go-restful/parameter.go
generated
vendored
8
vendor/github.com/emicklei/go-restful/parameter.go
generated
vendored
@@ -20,6 +20,9 @@ const (
|
||||
// FormParameterKind = indicator of Request parameter type "form"
|
||||
FormParameterKind
|
||||
|
||||
// MultiPartFormParameterKind = indicator of Request parameter type "multipart/form-data"
|
||||
MultiPartFormParameterKind
|
||||
|
||||
// CollectionFormatCSV comma separated values `foo,bar`
|
||||
CollectionFormatCSV = CollectionFormat("csv")
|
||||
|
||||
@@ -94,6 +97,11 @@ func (p *Parameter) beForm() *Parameter {
|
||||
return p
|
||||
}
|
||||
|
||||
func (p *Parameter) beMultiPartForm() *Parameter {
|
||||
p.data.Kind = MultiPartFormParameterKind
|
||||
return p
|
||||
}
|
||||
|
||||
// Required sets the required field and returns the receiver
|
||||
func (p *Parameter) Required(required bool) *Parameter {
|
||||
p.data.Required = required
|
||||
|
||||
Reference in New Issue
Block a user