Skip to content

Commit

Permalink
fix wrong type for format string
Browse files Browse the repository at this point in the history
  • Loading branch information
empiredan committed Dec 11, 2023
1 parent 9d08fbd commit 089aaa8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion collector/metrics/metric_collector.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func (collector *Collector) Start(tom *tomb.Tomb) error {
func getReplicaAddrs() ([]string, error) {
addrs := viper.GetStringSlice("meta_servers")
var rserverAddrs []string
for addr := range addrs {
for _, addr := range addrs {
url := fmt.Sprintf("http://%s/meta/nodes", addr)
resp, err := http.Get(url)
if err == nil && resp.StatusCode != http.StatusOK {
Expand Down

0 comments on commit 089aaa8

Please sign in to comment.