Skip to content

Commit

Permalink
fix clusterconfig to make it work like ok
Browse files Browse the repository at this point in the history
  • Loading branch information
arturrez committed Oct 17, 2024
1 parent b8b29b4 commit e691af8
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions pkg/application/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -804,12 +804,9 @@ func (app *Avalanche) ClusterExists(clusterName string) (bool, error) {

func (app *Avalanche) GetClusterConfig(clusterName string) (models.ClusterConfig, error) {
exists, err := app.ClusterExists(clusterName)
if err != nil {
if err != nil || !exists {
return models.ClusterConfig{}, err
}
if !exists {
return models.ClusterConfig{}, fmt.Errorf("cluster %q does not exist", clusterName)
}
clustersConfig, err := app.LoadClustersConfig()
if err != nil {
return models.ClusterConfig{}, err
Expand Down

0 comments on commit e691af8

Please sign in to comment.