aboutsummaryrefslogtreecommitdiffstats
path: root/rpc/args.go
diff options
context:
space:
mode:
authorTaylor Gerring <taylor.gerring@gmail.com>2015-03-23 23:34:50 +0800
committerTaylor Gerring <taylor.gerring@gmail.com>2015-03-23 23:34:50 +0800
commit2f8601ef382aeff6cdb31fe163cfac3b26bf56de (patch)
treebd8250bffff8aded3c07f3cca8954ad65eef03e9 /rpc/args.go
parent3f6e1b2fd3cbc6aeb1bbe658dd5b70945a57dffa (diff)
downloaddexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar.gz
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar.bz2
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar.lz
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar.xz
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.tar.zst
dexon-2f8601ef382aeff6cdb31fe163cfac3b26bf56de.zip
Rename blockAge to blockHeight
Diffstat (limited to 'rpc/args.go')
-rw-r--r--rpc/args.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/rpc/args.go b/rpc/args.go
index 06dab99bc..4b59f83b7 100644
--- a/rpc/args.go
+++ b/rpc/args.go
@@ -8,7 +8,7 @@ import (
"github.com/ethereum/go-ethereum/common"
)
-func blockAge(raw interface{}, number *int64) (err error) {
+func blockHeight(raw interface{}, number *int64) (err error) {
// Parse as integer
num, ok := raw.(float64)
if ok {
@@ -137,7 +137,7 @@ func (args *NewTxArgs) UnmarshalJSON(b []byte) (err error) {
return NewDecodeParamError(err.Error())
}
- if err := blockAge(raw, &args.BlockNumber); err != nil {
+ if err := blockHeight(raw, &args.BlockNumber); err != nil {
return err
}
}
@@ -174,7 +174,7 @@ func (args *GetStorageArgs) UnmarshalJSON(b []byte) (err error) {
args.Address = addstr
if len(obj) > 1 {
- if err := blockAge(obj[1], &args.BlockNumber); err != nil {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
return err
}
}
@@ -218,7 +218,7 @@ func (args *GetStorageAtArgs) UnmarshalJSON(b []byte) (err error) {
args.Key = keystr
if len(obj) > 2 {
- if err := blockAge(obj[2], &args.BlockNumber); err != nil {
+ if err := blockHeight(obj[2], &args.BlockNumber); err != nil {
return err
}
}
@@ -259,7 +259,7 @@ func (args *GetTxCountArgs) UnmarshalJSON(b []byte) (err error) {
args.Address = addstr
if len(obj) > 1 {
- if err := blockAge(obj[1], &args.BlockNumber); err != nil {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
return err
}
}
@@ -296,7 +296,7 @@ func (args *GetBalanceArgs) UnmarshalJSON(b []byte) (err error) {
args.Address = addstr
if len(obj) > 1 {
- if err := blockAge(obj[1], &args.BlockNumber); err != nil {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
return err
}
}
@@ -333,7 +333,7 @@ func (args *GetDataArgs) UnmarshalJSON(b []byte) (err error) {
args.Address = addstr
if len(obj) > 1 {
- if err := blockAge(obj[1], &args.BlockNumber); err != nil {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
return err
}
}