mirror of
https://github.com/portainer/portainer.git
synced 2025-07-23 15:29:42 +02:00
refactor(server): use httperror.NewError instead of struct [EE-6189] (#10398)
This commit is contained in:
parent
da346cba60
commit
95f3cf6e5b
26 changed files with 39 additions and 35 deletions
|
@ -100,7 +100,7 @@ func (handler *Handler) endpointUpdate(w http.ResponseWriter, r *http.Request) *
|
|||
}
|
||||
|
||||
if !isUnique {
|
||||
return httperror.NewError(http.StatusConflict, "Name is not unique", nil)
|
||||
return httperror.Conflict("Name is not unique", nil)
|
||||
}
|
||||
|
||||
endpoint.Name = name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue