Browse Source

CallResult空值不赋值

skyfffire 2 years ago
parent
commit
ec1eabb558
1 changed files with 2 additions and 2 deletions
  1. 2 2
      internal/ethapi/call_result.go

+ 2 - 2
internal/ethapi/call_result.go

@@ -4,7 +4,7 @@ import "github.com/ethereum/go-ethereum/common/hexutil"
 
 // CallResult is the result of one call.
 type CallResult struct {
-	Return  hexutil.Bytes `json:"return"`
-	Msg     string        `json:"message"`
+	Return  hexutil.Bytes `json:"return,omitempty"`
+	Msg     string        `json:"message,omitempty"`
 	Success bool          `json:"state"`
 }