forked from TrueCloudLab/frostfs-api-go
[#144] sdk/token: Use MarshalBinary to uuid of session token
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
5fa271e141
commit
2a7e91fa13
1 changed files with 6 additions and 1 deletions
|
@ -31,5 +31,10 @@ func (s SessionToken) SessionKey() []byte {
|
|||
}
|
||||
|
||||
func (s SessionToken) ID() []byte {
|
||||
return s.id[:]
|
||||
data, err := s.id.MarshalBinary()
|
||||
if err != nil {
|
||||
panic(err) // must never panic
|
||||
}
|
||||
|
||||
return data
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue