mirror of
https://github.com/coder/coder.git
synced 2025-07-09 11:45:56 +00:00
feat(site): Ask for version name and if it is active when publishing a new version on editor (#6756)
This commit is contained in:
@ -123,6 +123,9 @@ func (api *API) patchTemplateVersion(rw http.ResponseWriter, r *http.Request) {
|
||||
if errors.Is(err, errTemplateVersionNameConflict) {
|
||||
httpapi.Write(ctx, rw, http.StatusBadRequest, codersdk.Response{
|
||||
Message: err.Error(),
|
||||
Validations: []codersdk.ValidationError{
|
||||
{Field: "name", Detail: "Name is already used"},
|
||||
},
|
||||
})
|
||||
return
|
||||
}
|
||||
|
Reference in New Issue
Block a user