chore: support min go version 1.18 (#3511)
* chore: min go version 1.18 * fix build tag error * remove build tag * fix word * remove any.go * replace interface{} instead of any
This commit is contained in:
@ -652,7 +652,7 @@ func (c *Context) BindYAML(obj any) error {
|
||||
}
|
||||
|
||||
// BindTOML is a shortcut for c.MustBindWith(obj, binding.TOML).
|
||||
func (c *Context) BindTOML(obj interface{}) error {
|
||||
func (c *Context) BindTOML(obj any) error {
|
||||
return c.MustBindWith(obj, binding.TOML)
|
||||
}
|
||||
|
||||
@ -717,7 +717,7 @@ func (c *Context) ShouldBindYAML(obj any) error {
|
||||
}
|
||||
|
||||
// ShouldBindTOML is a shortcut for c.ShouldBindWith(obj, binding.TOML).
|
||||
func (c *Context) ShouldBindTOML(obj interface{}) error {
|
||||
func (c *Context) ShouldBindTOML(obj any) error {
|
||||
return c.ShouldBindWith(obj, binding.TOML)
|
||||
}
|
||||
|
||||
@ -995,7 +995,7 @@ func (c *Context) YAML(code int, obj any) {
|
||||
}
|
||||
|
||||
// TOML serializes the given struct as TOML into the response body.
|
||||
func (c *Context) TOML(code int, obj interface{}) {
|
||||
func (c *Context) TOML(code int, obj any) {
|
||||
c.Render(code, render.TOML{Data: obj})
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user