Skip to content

Commit

Permalink
revert RawBlockHeader author_auth_key for compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
nkysg committed Dec 13, 2024
1 parent b4b9eb3 commit f16a6c4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions types/src/block/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ use starcoin_vm_types::account_config::genesis_address;
use std::fmt::Formatter;
use std::hash::Hash;
use std::sync::Mutex;
use starcoin_vm_types::transaction::authenticator::AuthenticationKey;

/// Type for block number.
pub type BlockNumber = u64;
Expand Down Expand Up @@ -545,6 +546,7 @@ impl Into<RawBlockHeader> for BlockHeader {
timestamp: self.timestamp,
number: self.number,
author: self.author,
author_auth_key: None,
accumulator_root: self.txn_accumulator_root,
parent_block_accumulator_root: self.block_accumulator_root,
state_root: self.state_root,
Expand All @@ -566,6 +568,9 @@ pub struct RawBlockHeader {
pub number: BlockNumber,
/// Block author.
pub author: AccountAddress,
/// Block author auth key.
/// this field is deprecated
pub author_auth_key: Option<AuthenticationKey>,
/// The transaction accumulator root hash after executing this block.
pub accumulator_root: HashValue,
/// The parent block accumulator root hash.
Expand Down Expand Up @@ -1039,6 +1044,7 @@ impl BlockTemplate {
timestamp: self.timestamp,
number: self.number,
author: self.author,
author_auth_key: None,
accumulator_root: self.txn_accumulator_root,
parent_block_accumulator_root: self.block_accumulator_root,
state_root: self.state_root,
Expand Down

0 comments on commit f16a6c4

Please sign in to comment.