ipfs / go-cid

Content ID v1 implemented in go
MIT License
157 stars 47 forks source link

Use value receiver for MarshalJSON so we can marshal values #55

Closed phritz closed 6 years ago

phritz commented 6 years ago

This is a problem for go-cbor-ipld, see https://github.com/filecoin-project/go-filecoin/issues/626 and https://github.com/filecoin-project/go-filecoin/issues/599.

Stebalien commented 6 years ago

We really shouldn't be using MarshalJSON (we should have explicit transforms between the JSON format and the CBOR format)... but we're doing this anyways.