未验证 提交 36ec2cdc 编写于 作者: Z Zhengyi Lai

Bugfix: create repo have no workspace

Signed-off-by: NZhengyi Lai <zheng1@yunify.com>
上级 616fcb17
......@@ -753,6 +753,14 @@ func (h *openpitrixHandler) CreateRepo(req *restful.Request, resp *restful.Respo
api.HandleBadRequest(resp, nil, err)
return
}
if req.PathParameter("workspace") != "" {
if createRepoRequest.Workspace == nil {
createRepoRequest.Workspace = new(string)
}
*createRepoRequest.Workspace = req.PathParameter("workspace")
}
validate, _ := strconv.ParseBool(req.QueryParameter("validate"))
var result interface{}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册