Skip to content

Commit 39d15fa

Browse files
committed
Include KeyID when converting to/from Account Key protobuf messages
1 parent d526306 commit 39d15fa

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

client/convert/protobuf.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -358,6 +358,7 @@ func MessageToAccountKey(m *entities.AccountKey) (*flow.AccountKey, error) {
358358
}
359359

360360
return &flow.AccountKey{
361+
ID: int(m.GetIndex()),
361362
PublicKey: publicKey,
362363
SigAlgo: sigAlgo,
363364
HashAlgo: hashAlgo,
@@ -370,6 +371,7 @@ func AccountKeyToMessage(a *flow.AccountKey) (*entities.AccountKey, error) {
370371
publicKey := a.PublicKey.Encode()
371372

372373
return &entities.AccountKey{
374+
Index: uint32(a.ID),
373375
PublicKey: publicKey,
374376
SignAlgo: uint32(a.SigAlgo),
375377
HashAlgo: uint32(a.HashAlgo),

0 commit comments

Comments
 (0)