Skip to content

Commit

Permalink
Merge pull request #4856 from ipfs/fix/stats-bs-header
Browse files Browse the repository at this point in the history
cmds/stat: remove useless header if not polling
  • Loading branch information
whyrusleeping authored Mar 25, 2018
2 parents 4a4a28d + 21fae5b commit b1b96fc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion core/commands/stat.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,9 @@ Example:
defer re.Close()

polling, _ := res.Request().Options["poll"].(bool)
fmt.Fprintln(os.Stdout, "Total Up Total Down Rate Up Rate Down")
if polling {
fmt.Fprintln(os.Stdout, "Total Up Total Down Rate Up Rate Down")
}
for {
v, err := res.Next()
if !cmds.HandleError(err, res, re) {
Expand Down

0 comments on commit b1b96fc

Please sign in to comment.