Commit 6ebcf7aa authored by Jakub Sztandera's avatar Jakub Sztandera

blockstore: cleanup style a bit

License: MIT
Signed-off-by: default avatarJakub Sztandera <kubuxu@protonmail.ch>
parent 249be194
......@@ -102,12 +102,13 @@ func (b *arccache) PutMany(bs []blocks.Block) error {
}
}
err := b.blockstore.PutMany(bs)
if err == nil {
for _, block := range bs {
b.arc.Add(block.Key(), true)
}
if err != nil {
return err
}
return err
for _, block := range bs {
b.arc.Add(block.Key(), true)
}
return nil
}
func (b *arccache) AllKeysChan(ctx context.Context) (<-chan key.Key, error) {
......
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