[#520] Fix saving two lock types simultaneously

Signed-off-by: Denis Kirillov <denis@nspcc.ru>
This commit is contained in:
Denis Kirillov 2022-06-08 15:33:00 +03:00 committed by Alex Vanin
parent 87d19f09f7
commit d8ab1b4799

View file

@ -907,7 +907,8 @@ func (c *TreeClient) PutLock(ctx context.Context, cnrID *cid.ID, nodeID uint64,
if lock.LegalHoldOID != nil {
meta[legalHoldOIDKV] = lock.LegalHoldOID.EncodeToString()
} else if lock.RetentionOID != nil {
}
if lock.RetentionOID != nil {
meta[retentionOIDKV] = lock.RetentionOID.EncodeToString()
meta[untilDateKV] = lock.UntilDate
if lock.IsCompliance {