Regularize JSON stuff

This commit is contained in:
Adam Ierymenko 2019-10-02 09:34:44 -07:00
commit c3e0f262d1
No known key found for this signature in database
GPG key ID: C8877CF2D7A5D7F3
13 changed files with 164 additions and 114 deletions

View file

@ -49,7 +49,7 @@ func (a Address) String() string {
// MarshalJSON marshals this Address as a string
func (a Address) MarshalJSON() ([]byte, error) {
return []byte("\"" + a.String() + "\""), nil
return []byte(fmt.Sprintf("\"%.10x\"", uint64(a))), nil
}
// UnmarshalJSON unmarshals this Address from a string