Skip to content

Commit

Permalink
fix build.
Browse files Browse the repository at this point in the history
  • Loading branch information
RustNinja committed Sep 12, 2023
1 parent 2059cf3 commit 8cfb09d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion light-clients/common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ pub fn decode_timestamp_extrinsic(ext: &Vec<u8>) -> Result<u64, anyhow::Error> {
// https://github.com/paritytech/substrate/blob/d602397a0bbb24b5d627795b797259a44a5e29e9/primitives/trie/src/lib.rs#L99-L101
// Decoding from the [2..] because the timestamp inmherent has two extra bytes before the call
// that represents the call length and the extrinsic version.
let ret: Compact<u64> = codec::Decode::decode(&mut &ext[5..])
let timestamp: Compact<u64> = codec::Decode::decode(&mut &ext[5..])
.map_err(|err| anyhow!("Failed to decode extrinsic: {err}"))?;
Ok(timestamp.into())
}
Expand Down

0 comments on commit 8cfb09d

Please sign in to comment.