Commit 5f9214c8 authored by Steven Allen's avatar Steven Allen

fix: return raw block CIDs instead of V0 CIDs from AllKeysChan

V0 CIDs are always "dag-pb". Using the "raw" codec indicates that these blocks
are just raw data.
parent e62b875f
...@@ -224,10 +224,7 @@ func (bs *blockstore) AllKeysChan(ctx context.Context) (<-chan cid.Cid, error) { ...@@ -224,10 +224,7 @@ func (bs *blockstore) AllKeysChan(ctx context.Context) (<-chan cid.Cid, error) {
log.Warningf("error parsing key from binary: %s", err) log.Warningf("error parsing key from binary: %s", err)
continue continue
} }
k, err := cid.Cast(bk) k := cid.NewCidV1(cid.Raw, bk)
if err != nil {
log.Warningf("failed to cast cid: %s", err)
}
select { select {
case <-ctx.Done(): case <-ctx.Done():
return return
......
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