Skip to content

Commit

Permalink
fix(api): fix invalid error message
Browse files Browse the repository at this point in the history
  • Loading branch information
JacieChao authored and Jason-ZW committed Mar 17, 2021
1 parent 9a6ccd6 commit 1374430
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/server/store/cluster/store.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ func (c *Store) Create(apiOp *types.APIRequest, schema *types.APISchema, data ty
return types.APIObject{}, apierror.NewAPIError(validation.NotFound, err.Error())
}
err = p.SetConfig(b)
if err != nil {
return types.APIObject{}, apierror.NewAPIError(validation.InvalidOption, err.Error())
}
id := p.GenerateClusterName()
// save credential config
if providerName != "native" {
Expand Down

0 comments on commit 1374430

Please sign in to comment.