Merge pull request #6763 from maxm123/master

Fix error handling problem in APIv2 network remove
This commit is contained in:
OpenShift Merge Robot 2020-06-29 04:59:34 -04:00 committed by GitHub
commit cbae41f75f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -285,7 +285,7 @@ func RemoveNetwork(w http.ResponseWriter, r *http.Request) {
return
}
if !exists {
utils.Error(w, "network not found", http.StatusNotFound, err)
utils.Error(w, "network not found", http.StatusNotFound, network.ErrNetworkNotFound)
return
}
if err := network.RemoveNetwork(config, name); err != nil {