[#1460] blobovnicza: Do not use pointers as the results

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2022-05-31 15:22:32 +03:00 committed by Pavel Karpy
parent 0e4a1beecf
commit 010253a97a
4 changed files with 12 additions and 12 deletions

View file

@ -29,7 +29,7 @@ func (p *DeletePrm) SetAddress(addr oid.Address) {
// Returns an error of type apistatus.ObjectNotFound if the object to be deleted is not in blobovnicza.
//
// Should not be called in read-only configuration.
func (b *Blobovnicza) Delete(prm DeletePrm) (*DeleteRes, error) {
func (b *Blobovnicza) Delete(prm DeletePrm) (DeleteRes, error) {
addrKey := addressKey(prm.addr)
removed := false
@ -67,8 +67,8 @@ func (b *Blobovnicza) Delete(prm DeletePrm) (*DeleteRes, error) {
if err == nil && !removed {
var errNotFound apistatus.ObjectNotFound
return nil, errNotFound
return DeleteRes{}, errNotFound
}
return nil, err
return DeleteRes{}, err
}