forked from TrueCloudLab/frostfs-node
[#1598] golangci: Enable unparam linter
To drop unnecessary parameters and return values. Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
4d5ae59a52
commit
fb928616cc
26 changed files with 123 additions and 155 deletions
|
@ -161,21 +161,21 @@ func (db *DB) deleteGroup(tx *bbolt.Tx, addrs []oid.Address) (DeleteRes, error)
|
|||
|
||||
func (db *DB) updateCountersDelete(tx *bbolt.Tx, res DeleteRes) error {
|
||||
if res.phyCount > 0 {
|
||||
err := db.updateShardObjectCounter(tx, phy, res.phyCount, false)
|
||||
err := db.decShardObjectCounter(tx, phy, res.phyCount)
|
||||
if err != nil {
|
||||
return fmt.Errorf("decrease phy object counter: %w", err)
|
||||
}
|
||||
}
|
||||
|
||||
if res.logicCount > 0 {
|
||||
err := db.updateShardObjectCounter(tx, logical, res.logicCount, false)
|
||||
err := db.decShardObjectCounter(tx, logical, res.logicCount)
|
||||
if err != nil {
|
||||
return fmt.Errorf("decrease logical object counter: %w", err)
|
||||
}
|
||||
}
|
||||
|
||||
if res.userCount > 0 {
|
||||
err := db.updateShardObjectCounter(tx, user, res.userCount, false)
|
||||
err := db.decShardObjectCounter(tx, user, res.userCount)
|
||||
if err != nil {
|
||||
return fmt.Errorf("decrease user object counter: %w", err)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue