Commit 08e15f8a authored by Steven Allen's avatar Steven Allen

chore: avoid re-validated already validated CIDs

parent 58b483a8
......@@ -38,7 +38,7 @@ func (p V0Builder) Sum(data []byte) (Cid, error) {
if err != nil {
return Undef, err
}
return NewCidV0(hash), nil
return Cid{string(hash)}, nil
}
func (p V0Builder) GetCodec() uint64 {
......
......@@ -613,7 +613,7 @@ func CidFromBytes(data []byte) (int, Cid, error) {
return 0, Undef, err
}
return 34, NewCidV0(h), nil
return 34, Cid{string(h)}, nil
}
vers, n := binary.Uvarint(data)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment