aicra/internal/request/parameter.go

15 lines
253 B
Go
Raw Permalink Normal View History

package request
2018-06-01 08:51:51 +00:00
// Parse parameter (json-like) if not already done
func (i *Parameter) Parse() {
/* (1) Stop if already parsed or nil*/
if i.Parsed || i.Value == nil {
return
}
/* (2) Try to parse value */
i.Value = parseParameter(i.Value)
}