aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Wilcke <jeffrey@ethereum.org>2015-05-28 00:05:46 +0800
committerJeffrey Wilcke <jeffrey@ethereum.org>2015-05-28 00:05:46 +0800
commit903b95fffabf0f8c94594b69d95747772e6abed8 (patch)
treed5fa73d362f339ae728e4a1a9481104d5389dc6e
parent8951a03db39a2a877ada34c927d78352d465303e (diff)
parent3f91ee4ff824b38b7775f4e9f51a4160f5edc19d (diff)
downloaddexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar.gz
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar.bz2
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar.lz
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar.xz
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.tar.zst
dexon-903b95fffabf0f8c94594b69d95747772e6abed8.zip
Merge pull request #1124 from karalabe/detaied-download-progress
cmd/geth: expand admin.progress() to something meaningful
-rw-r--r--cmd/geth/admin.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/geth/admin.go b/cmd/geth/admin.go
index 8f9a009d7..f0be444c6 100644
--- a/cmd/geth/admin.go
+++ b/cmd/geth/admin.go
@@ -262,8 +262,8 @@ func (js *jsre) setHead(call otto.FunctionCall) otto.Value {
}
func (js *jsre) downloadProgress(call otto.FunctionCall) otto.Value {
- current, max := js.ethereum.Downloader().Stats()
- v, _ := call.Otto.ToValue(fmt.Sprintf("%d/%d", current, max))
+ pending, cached := js.ethereum.Downloader().Stats()
+ v, _ := call.Otto.ToValue(map[string]interface{}{"pending": pending, "cached": cached})
return v
}