mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-10-25 05:05:03 +00:00
babe: fix deprecated function in transcript (#4996)
This commit is contained in:
1 parent
0910175e10
commit
0c5ea06704
1 file changed
+3
-4
@@ -86,16 +86,15 @@ pub(super) fn secondary_slot_author(
|
||||
Some(&expected_author.0)
|
||||
}
|
||||
|
||||
#[allow(deprecated)]
|
||||
pub(super) fn make_transcript(
|
||||
randomness: &[u8],
|
||||
slot_number: u64,
|
||||
epoch: u64,
|
||||
) -> Transcript {
|
||||
let mut transcript = Transcript::new(&BABE_ENGINE_ID);
|
||||
transcript.commit_bytes(b"slot number", &slot_number.to_le_bytes());
|
||||
transcript.commit_bytes(b"current epoch", &epoch.to_le_bytes());
|
||||
transcript.commit_bytes(b"chain randomness", randomness);
|
||||
transcript.append_message(b"slot number", &slot_number.to_le_bytes());
|
||||
transcript.append_message(b"current epoch", &epoch.to_le_bytes());
|
||||
transcript.append_message(b"chain randomness", randomness);
|
||||
transcript
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user