Skip to content

Commit

Permalink
allow comma separated rpc hosts
Browse files Browse the repository at this point in the history
  • Loading branch information
pk910 committed Oct 11, 2023
1 parent 978c770 commit a9c749c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cmd/blob-spammer/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,13 @@ func main() {
logrus.SetLevel(logrus.DebugLevel)
}

rpcHosts := cliArgs.rpchosts
rpcHosts := []string{}
for _, rpcHost := range strings.Split(strings.Join(cliArgs.rpchosts, ","), ",") {
if rpcHost != "" {
rpcHosts = append(rpcHosts, rpcHost)
}
}

if cliArgs.rpchostsFile != "" {
fileLines, err := utils.ReadFileLinesTrimmed(cliArgs.rpchostsFile)
if err != nil {
Expand Down

0 comments on commit a9c749c

Please sign in to comment.