[#1423] session: Upgrade SDK package
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
dda56f1319
commit
4c8ec20e32
41 changed files with 740 additions and 663 deletions
|
@ -24,19 +24,17 @@ func Put(c *Client, cnr *container.Container) (*cid.ID, error) {
|
|||
return nil, fmt.Errorf("can't marshal container: %w", err)
|
||||
}
|
||||
|
||||
binToken, err := cnr.SessionToken().Marshal()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("could not marshal session token: %w", err)
|
||||
}
|
||||
|
||||
name, zone := container.GetNativeNameWithZone(cnr)
|
||||
|
||||
var prm PutPrm
|
||||
prm.SetContainer(data)
|
||||
prm.SetToken(binToken)
|
||||
prm.SetName(name)
|
||||
prm.SetZone(zone)
|
||||
|
||||
if tok := cnr.SessionToken(); tok != nil {
|
||||
prm.SetToken(tok.Marshal())
|
||||
}
|
||||
|
||||
if sig := cnr.Signature(); sig != nil {
|
||||
// TODO(@cthulhu-rider): #1387 implement and use another approach to avoid conversion
|
||||
var sigV2 refs.Signature
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue