mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-11-15 15:17:07 +00:00
extract out runtime-codec to a separate crate
This commit is contained in:
1 parent
8e554129ec
commit
a68b187f4d
27 files changed
+82
-40
No files matched your search
@@ -24,7 +24,7 @@ use codec::{Slicable, KeyedVec};
|
||||
|
||||
/// Return the value of the item in storage under `key`, or `None` if there is no explicit entry.
|
||||
pub fn get<T: Slicable + Sized>(key: &[u8]) -> Option<T> {
|
||||
Slicable::set_as_slice(&|out, offset|
|
||||
Slicable::set_as_slice(|out, offset|
|
||||
runtime_std::read_storage(&twox_128(key)[..], out, offset) >= out.len()
|
||||
)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user