1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-25 00:09:40 +02:00

chore(edgestacks): clean up EE-4851 (#8260)

This commit is contained in:
andres-portainer 2023-01-03 10:49:29 -03:00 committed by GitHub
parent 137ce37096
commit 2fc518f221
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 23 additions and 35 deletions

View file

@ -55,10 +55,8 @@ func (handler *Handler) edgeStackUpdate(w http.ResponseWriter, r *http.Request)
}
stack, err := handler.DataStore.EdgeStack().EdgeStack(portainer.EdgeStackID(stackID))
if handler.DataStore.IsErrObjectNotFound(err) {
return httperror.NotFound("Unable to find a stack with the specified identifier inside the database", err)
} else if err != nil {
return httperror.InternalServerError("Unable to find a stack with the specified identifier inside the database", err)
if err != nil {
return handler.handlerDBErr(err, "Unable to find a stack with the specified identifier inside the database")
}
var payload updateEdgeStackPayload