Skip to content

Commit

Permalink
Merge pull request #10443 from Quasilyte/quasilyte/fix_args_order
Browse files Browse the repository at this point in the history
etcdctl: fix strings.HasPrefix args order
  • Loading branch information
xiang90 committed Feb 2, 2019
2 parents be40b1d + 48a2442 commit 1fe6f10
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion etcdctl/ctlv2/command/util.go
Expand Up @@ -104,7 +104,7 @@ func getDomainDiscoveryFlagValue(c *cli.Context) ([]string, error) {
// strip insecure connections
ret := []string{}
for _, ep := range eps {
if strings.HasPrefix("http://", ep) {
if strings.HasPrefix(ep, "http://") {
fmt.Fprintf(os.Stderr, "ignoring discovered insecure endpoint %q\n", ep)
continue
}
Expand Down
2 changes: 1 addition & 1 deletion etcdctl/ctlv3/command/global.go
Expand Up @@ -444,7 +444,7 @@ func endpointsFromFlagValue(cmd *cobra.Command) ([]string, error) {
// strip insecure connections
ret := []string{}
for _, ep := range eps {
if strings.HasPrefix("http://", ep) {
if strings.HasPrefix(ep, "http://") {
fmt.Fprintf(os.Stderr, "ignoring discovered insecure endpoint %q\n", ep)
continue
}
Expand Down

0 comments on commit 1fe6f10

Please sign in to comment.