cmn: fix HexBytes.MarshalJSON

This commit is contained in:
Ethan Buchman
2018-01-02 11:05:53 -05:00
parent 1460540acd
commit 2bb538b150
2 changed files with 3 additions and 3 deletions

View File

@ -26,7 +26,7 @@ func (bz HexBytes) MarshalJSON() ([]byte, error) {
jbz := make([]byte, len(s)+2)
jbz[0] = '"'
copy(jbz[1:], []byte(s))
jbz[1] = '"'
jbz[len(jbz)-1] = '"'
return jbz, nil
}