Skip to content

Commit

Permalink
Tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
Nashtare committed Sep 17, 2024
1 parent 0375163 commit 2a86e73
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion trace_decoder/src/typed_mpt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ impl TrieKey {
pub fn from_slot_position(pos: U256) -> Self {
let mut bytes = [0; 32];
pos.to_big_endian(&mut bytes);
Self::from_hash(keccak_hash::keccak(bytes))
Self::from_hash(keccak_hash::keccak(H256::from_slice(&bytes)))
}
pub fn from_hash(H256(bytes): H256) -> Self {
Self::new(AsNibbles(bytes)).expect("32 bytes is 64 nibbles, which fits")
Expand Down
2 changes: 1 addition & 1 deletion zero/src/rpc/native/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ fn insert_beacon_roots_update(
(timestamp % chunk).into(), // timestamp_idx
((timestamp % chunk) + chunk).into(), // root_idx
]);
state_access.insert(BEACON_ROOTS_CONTRACT_ADDRESS.0.into(), keys);
state_access.insert(BEACON_ROOTS_CONTRACT_ADDRESS.as_fixed_bytes().into(), keys);

Ok(())
}
Expand Down

0 comments on commit 2a86e73

Please sign in to comment.