提交 e74db544 编写于 作者: U UlricQin

node post api support chinese

上级 5f14e76b
backend:
maxConns: 20000
# in ms
# connTimeout: 1000
# callTimeout: 3000
......
......@@ -35,10 +35,6 @@ func nodePost(c *gin.Context) {
errors.Bomb("leaf invalid")
}
if !str.IsMatch(f.Name, `^[a-zA-Z0-9\-]+$`) {
errors.Bomb("name valid characters: [a-zA-Z0-9] and -")
}
parent, err := model.NodeGet("id", f.Pid)
errors.Dangerous(err)
......@@ -73,10 +69,6 @@ func nodeNamePut(c *gin.Context) {
var f nodeNameForm
errors.Dangerous(c.ShouldBind(&f))
if !str.IsMatch(f.Name, `^[a-zA-Z0-9\-]+$`) {
errors.Bomb("name valid characters: [a-zA-Z0-9] and -")
}
node, err := model.NodeGet("id", urlParamInt64(c, "id"))
errors.Dangerous(err)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册