diff options
Diffstat (limited to 'src/k8splugin/internal/connection/connectionhandler.go')
-rw-r--r-- | src/k8splugin/internal/connection/connectionhandler.go | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/k8splugin/internal/connection/connectionhandler.go b/src/k8splugin/internal/connection/connectionhandler.go index ddb43f57..0f8014fa 100644 --- a/src/k8splugin/internal/connection/connectionhandler.go +++ b/src/k8splugin/internal/connection/connectionhandler.go @@ -47,7 +47,7 @@ func (h ConnectionHandler) CreateHandler(w http.ResponseWriter, r *http.Request) } // Name is required. - if v.ConnectionName == "" { + if v.CloudRegion == "" { http.Error(w, "Missing name in POST request", http.StatusBadRequest) return } @@ -58,13 +58,7 @@ func (h ConnectionHandler) CreateHandler(w http.ResponseWriter, r *http.Request) return } - // CloudRegionID is required. - if v.CloudRegionID == "" { - http.Error(w, "Missing CloudRegionID in POST request", http.StatusBadRequest) - return - } - - // CloudRegionID is required. + // Kubeconfig is required. if v.Kubeconfig == nil { http.Error(w, "Missing Kubeconfig in POST request", http.StatusBadRequest) return |