[#195] Set Lock type to system lock objects

Signed-off-by: Denis Kirillov <denis@nspcc.ru>
This commit is contained in:
Denis Kirillov 2022-03-04 17:36:30 +03:00 committed by Angira Kekteeva
parent 13080d6d96
commit 32e83db064
8 changed files with 39 additions and 10 deletions

View file

@ -204,6 +204,7 @@ func (n *layer) objectPut(ctx context.Context, bkt *data.BucketInfo, p *PutObjec
if p.Lock != nil {
objInfo := &data.ObjectInfo{ID: id, Name: p.Object}
p.Lock.Objects = append(p.Lock.Objects, *id)
if p.Lock.LegalHold {
if err = n.putLockObject(ctx, bkt, objInfo.LegalHoldObject(), p.Lock); err != nil {
return nil, err