diff --git a/shared/src/ledger/storage/merkle_tree.rs b/shared/src/ledger/storage/merkle_tree.rs index edd4d2b452..b23e9db7de 100644 --- a/shared/src/ledger/storage/merkle_tree.rs +++ b/shared/src/ledger/storage/merkle_tree.rs @@ -56,7 +56,7 @@ pub enum Error { type Result = std::result::Result; /// Type alias for bytes to be put into the Merkle storage -pub(super) type StorageBytes<'a> = &'a [u8]; +pub(super) type StorageBytes<'a> = std::borrow::Cow<'a, [u8]>; /// Type aliases for the different merkle trees and backing stores pub type SmtStore = DefaultStore;