diff options
author | Taylor Gerring <taylor.gerring@gmail.com> | 2015-04-02 18:30:42 +0800 |
---|---|---|
committer | Taylor Gerring <taylor.gerring@gmail.com> | 2015-04-02 18:30:42 +0800 |
commit | cc45b4d8b536a53b59696389e3609c2f633d07a7 (patch) | |
tree | bb0fa7684ff4dfc54f0d0d76fccb0d29b005035e /rpc | |
parent | f89baa73e5cfc0e93f32e36f5c3838cd808e6f46 (diff) | |
download | dexon-cc45b4d8b536a53b59696389e3609c2f633d07a7.tar.gz dexon-cc45b4d8b536a53b59696389e3609c2f633d07a7.tar.zst dexon-cc45b4d8b536a53b59696389e3609c2f633d07a7.zip |
Trim left only, not right
Diffstat (limited to 'rpc')
-rw-r--r-- | rpc/types.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rpc/types.go b/rpc/types.go index 53a2a0806..83542c83d 100644 --- a/rpc/types.go +++ b/rpc/types.go @@ -104,7 +104,7 @@ func (d *hexnum) String() string { // Get hex string from bytes out := common.Bytes2Hex(d.data) // Trim leading 0s - out = strings.Trim(out, "0") + out = strings.TrimLeft(out, "0") // Output "0x0" when value is 0 if len(out) == 0 { out = "0" |