Skip to content

Commit

Permalink
Remove unused func.
Browse files Browse the repository at this point in the history
  • Loading branch information
vmihailenco committed Apr 7, 2015
1 parent 2511a17 commit dbfd757
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,6 @@ import (
"time"
)

func removeDuplicates(slice []string) []string {
seen := make(map[string]struct{}, len(slice))
for i := 0; i < len(slice); {
addr := slice[i]
if _, ok := seen[addr]; ok {
slice = append(slice[:i], slice[i+1:]...)
} else {
seen[addr] = struct{}{}
i++
}
}
return slice
}

type ClusterClient struct {
commandable

Expand Down Expand Up @@ -285,7 +271,6 @@ func (opt *ClusterOptions) getMaxRedirects() int {
}

func (opt *ClusterOptions) getAddrs() []string {
opt.Addrs = removeDuplicates(opt.Addrs)
return opt.Addrs
}

Expand Down

0 comments on commit dbfd757

Please sign in to comment.