[#1418] shard: Do not use pointers as parameters

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2022-05-20 21:08:59 +03:00 committed by fyrchik
parent e265ce2d52
commit 6e752f36dc
39 changed files with 205 additions and 161 deletions

View file

@ -83,9 +83,9 @@ func (e *StorageEngine) head(prm *HeadPrm) (*HeadRes, error) {
outError error = errNotFound
)
shPrm := new(shard.HeadPrm).
WithAddress(prm.addr).
WithRaw(prm.raw)
var shPrm shard.HeadPrm
shPrm.WithAddress(prm.addr)
shPrm.WithRaw(prm.raw)
e.iterateOverSortedShards(prm.addr, func(_ int, sh hashedShard) (stop bool) {
res, err := sh.Head(shPrm)