[问题] ReadQuery 无法解析带下划线的字段。
作者: 0854321创建于 2025年9月13日更新于 2025年9月15日
标签🤔 type:question
Describe the bug When using the ReadQuery method in the Iris framework to parse URL query parameters from a GET request, parameters with snake_case naming (e.g., team_id) are not parsed correctly. In contrast, camelCase parameters (e.g., environmentId) are parsed successfully. Even when the struct field is tagged with form:"team_id", ReadQuery fails to bind the value, leaving the field with its zero value (e.g., team_id = 0).
内容来源: kataras/iris