Skip to content

Commit 34dac20

Browse files
authored
docs: fix BindXML comment referencing nonexistent binding.BindXML (#4717)
The doc comment on line 790 read: "BindXML is a shortcut for c.MustBindWith(obj, binding.BindXML)." `binding.BindXML` does not exist. The correct symbol is `binding.XML` (defined in binding/binding.go), which is also what the implementation uses. All sibling methods (BindJSON, BindYAML, BindTOML, etc.) already reference the correct symbol in their comments.
1 parent 03f3e42 commit 34dac20

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

context.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -787,7 +787,7 @@ func (c *Context) BindJSON(obj any) error {
787787
return c.MustBindWith(obj, binding.JSON)
788788
}
789789

790-
// BindXML is a shortcut for c.MustBindWith(obj, binding.BindXML).
790+
// BindXML is a shortcut for c.MustBindWith(obj, binding.XML).
791791
func (c *Context) BindXML(obj any) error {
792792
return c.MustBindWith(obj, binding.XML)
793793
}

0 commit comments

Comments
 (0)