1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-19 19:07:06 +00:00

respect the iris.WithEmptyFormError option on Context.ReadQuery too

as requested at: #1727
This commit is contained in:
Gerasimos (Makis) Maropoulos
2021-02-14 13:40:56 +02:00
parent d26b9bfbed
commit 567c06702f
6 changed files with 28 additions and 7 deletions

View File

@@ -39,7 +39,7 @@ func Parse(fullpath string, paramTypes []ast.ParamType) ([]*ast.ParamStatement,
}
// if we have param type path but it's not the last path part
if ast.IsTrailing(stmt.Type) && i < len(pathParts)-1 {
return nil, fmt.Errorf("%s: parameter type \"%s\" should be registered to the very last of a path", s, stmt.Type.Indent())
return nil, fmt.Errorf("%s: parameter type \"%s\" should be registered to the very end of a path", s, stmt.Type.Indent())
}
statements = append(statements, stmt)