diff --git a/api/http/handler/edgestacks/edgestack_status_update.go b/api/http/handler/edgestacks/edgestack_status_update.go index c38300a49..6a8b1e535 100644 --- a/api/http/handler/edgestacks/edgestack_status_update.go +++ b/api/http/handler/edgestacks/edgestack_status_update.go @@ -71,7 +71,7 @@ func (handler *Handler) edgeStackStatusUpdate(w http.ResponseWriter, r *http.Req var stack *portainer.EdgeStack if err := handler.DataStore.UpdateTx(func(tx dataservices.DataStoreTx) error { - if r.Context().Err() != nil { + if err := r.Context().Err(); err != nil { return err }