From 0c866f62c5821039fdfd3accbf8f5c8fa0443d42 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Tue, 27 Jun 2023 11:12:01 +0300 Subject: [PATCH] [#473] placement: Fix backwards compatibility for `copies_number` Signed-off-by: Evgenii Stratonikov --- pkg/services/object_manager/placement/traverser.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/services/object_manager/placement/traverser.go b/pkg/services/object_manager/placement/traverser.go index 7b9b26a0b..47f79a627 100644 --- a/pkg/services/object_manager/placement/traverser.go +++ b/pkg/services/object_manager/placement/traverser.go @@ -86,7 +86,7 @@ func NewTraverser(opts ...Option) (*Traverser, error) { } // backward compatibility for scalar `copies_number` - if len(cfg.copyNumbers) == 1 { + if len(cfg.copyNumbers) == 1 && cfg.copyNumbers[0] != 0 { cfg.flatSuccess = &cfg.copyNumbers[0] } -- 2.45.2