mirror of
https://github.com/lightninglabs/lightning-terminal.git
synced 2026-08-13 12:33:36 +02:00
session_rpcserver: marshal RevokedAt field
This commit is contained in:
parent
5ffa428a8e
commit
46745ce892
1 changed files with 6 additions and 0 deletions
|
|
@ -519,6 +519,11 @@ func marshalRPCSession(sess *session.Session) (*litrpc.Session, error) {
|
|||
|
||||
macRecipe := marshalRPCMacaroonRecipe(sess.MacaroonRecipe)
|
||||
|
||||
var revokedAt uint64
|
||||
if !sess.RevokedAt.IsZero() {
|
||||
revokedAt = uint64(sess.RevokedAt.Unix())
|
||||
}
|
||||
|
||||
return &litrpc.Session{
|
||||
Label: sess.Label,
|
||||
SessionState: rpcState,
|
||||
|
|
@ -531,6 +536,7 @@ func marshalRPCSession(sess *session.Session) (*litrpc.Session, error) {
|
|||
LocalPublicKey: sess.LocalPublicKey.SerializeCompressed(),
|
||||
RemotePublicKey: remotePubKey,
|
||||
CreatedAt: uint64(sess.CreatedAt.Unix()),
|
||||
RevokedAt: revokedAt,
|
||||
MacaroonRecipe: macRecipe,
|
||||
}, nil
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue