[#2000] cli: Provide a bearer token to spawned HEAD by DELETE

If a `neofs-cli object delete` operation is performing using a bearer token,
add it to the new `HEAD` requests that collects children OIDs.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2022-11-09 16:23:59 +03:00 committed by fyrchik
parent b0e94b6a6b
commit 37f813604f
2 changed files with 3 additions and 0 deletions

View file

@ -345,6 +345,8 @@ func collectObjectRelatives(cmd *cobra.Command, cli *client.Client, cnr cid.ID,
prmHead.SetAddress(addrObj)
prmHead.SetRawFlag(true)
Prepare(cmd, &prmHead)
_, err := internal.HeadObject(prmHead)
var errSplit *object.SplitInfoError