[#1718] linter: Resolve gocritic's appendAssign linter
See https://go-critic.com/overview#appendassign for details. Change-Id: I991979ea680af25e2cec9097fa12b1c4eebc6c1d Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
86264e4e20
commit
cf48069fd8
1 changed files with 2 additions and 7 deletions
|
@ -262,13 +262,8 @@ func OpenSessionViaClient(cmd *cobra.Command, dst SessionPrm, cli *client.Client
|
||||||
if _, ok := dst.(*internal.DeleteObjectPrm); ok {
|
if _, ok := dst.(*internal.DeleteObjectPrm); ok {
|
||||||
common.PrintVerbose(cmd, "Collecting relatives of the removal object...")
|
common.PrintVerbose(cmd, "Collecting relatives of the removal object...")
|
||||||
|
|
||||||
rels := collectObjectRelatives(cmd, cli, cnr, *obj)
|
objs = collectObjectRelatives(cmd, cli, cnr, *obj)
|
||||||
|
objs = append(objs, *obj)
|
||||||
if len(rels) == 0 {
|
|
||||||
objs = []oid.ID{*obj}
|
|
||||||
} else {
|
|
||||||
objs = append(rels, *obj)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue