mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-07 16:55:46 +00:00
Simplify keccak call
This commit is contained in:
@@ -16,8 +16,7 @@ use hash_db::Hasher;
|
|||||||
use types::Hash256;
|
use types::Hash256;
|
||||||
|
|
||||||
pub fn keccak256(bytes: &[u8]) -> Hash256 {
|
pub fn keccak256(bytes: &[u8]) -> Hash256 {
|
||||||
let hash: [u8; 32] = alloy_primitives::utils::keccak256(bytes).into();
|
Hash256::from(alloy_primitives::utils::keccak256(bytes).as_ref())
|
||||||
Hash256::from(hash)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Keccak hasher.
|
/// Keccak hasher.
|
||||||
|
|||||||
Reference in New Issue
Block a user