aboutsummaryrefslogtreecommitdiffstats
path: root/ethutil
diff options
context:
space:
mode:
Diffstat (limited to 'ethutil')
-rw-r--r--ethutil/value.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/ethutil/value.go b/ethutil/value.go
index 04131aba9..b7756f9b1 100644
--- a/ethutil/value.go
+++ b/ethutil/value.go
@@ -20,7 +20,12 @@ func (val *Value) String() string {
}
func NewValue(val interface{}) *Value {
- return &Value{Val: val}
+ t := val
+ if v, ok := val.(*Value); ok {
+ t = v.Val
+ }
+
+ return &Value{Val: t}
}
func (val *Value) Type() reflect.Kind {