Skip to content

Commit 26d5df1

Browse files
authored
fix: remove redundant B256 conversion in linea consensus
1 parent e16f337 commit 26d5df1

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

linea/src/consensus.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -176,12 +176,7 @@ pub fn verify_block(curr_signer: Address, block: &Block<Transaction>) -> Result<
176176
let mut header = block.header.inner.clone();
177177
header.extra_data = prefix;
178178

179-
let sighash: [u8; 32] = header
180-
.hash_slow()
181-
.to_vec()
182-
.try_into()
183-
.expect("Failed to convert header hash to fixed array");
184-
let sighash = B256::new(sighash);
179+
let sighash = header.hash_slow();
185180

186181
let pk = signature
187182
.recover_from_prehash(&sighash)

0 commit comments

Comments
 (0)