Skip to content

Commit

Permalink
fix(tidb-client): wrong status api property (#944)
Browse files Browse the repository at this point in the history
  • Loading branch information
shhdgit authored Jun 28, 2021
1 parent fd9f9e6 commit baf12c9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/tidb/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -172,11 +172,11 @@ func (c *Client) Get(relativeURI string) (*httpc.Response, error) {
var addr string
switch {
case c.enforceStatusAPIAddresss:
addr = c.sqlAPIAddress
addr = c.statusAPIAddress
case overrideEndpoint != "":
addr = overrideEndpoint
default:
addr = c.sqlAPIAddress
addr = c.statusAPIAddress
}
if addr == "" {
if addr, err = c.forwarder.getEndpointAddr(c.forwarder.statusPort); err != nil {
Expand Down

0 comments on commit baf12c9

Please sign in to comment.