mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 18:07:58 +00:00
Aura and Slots refactoring (#8386)
* Make slot duration being exposed as `Duration` to the outside * Some slot info love * Add `build_aura_worker` utility function * Copy copy copy
This commit is contained in:
@@ -762,7 +762,10 @@ cfg_if! {
|
||||
}
|
||||
|
||||
impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
|
||||
fn slot_duration() -> u64 { 1000 }
|
||||
fn slot_duration() -> sp_consensus_aura::SlotDuration {
|
||||
sp_consensus_aura::SlotDuration::from_millis(1000)
|
||||
}
|
||||
|
||||
fn authorities() -> Vec<AuraId> {
|
||||
system::authorities().into_iter().map(|a| {
|
||||
let authority: sr25519::Public = a.into();
|
||||
@@ -1020,7 +1023,10 @@ cfg_if! {
|
||||
}
|
||||
|
||||
impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
|
||||
fn slot_duration() -> u64 { 1000 }
|
||||
fn slot_duration() -> sp_consensus_aura::SlotDuration {
|
||||
sp_consensus_aura::SlotDuration::from_millis(1000)
|
||||
}
|
||||
|
||||
fn authorities() -> Vec<AuraId> {
|
||||
system::authorities().into_iter().map(|a| {
|
||||
let authority: sr25519::Public = a.into();
|
||||
|
||||
Reference in New Issue
Block a user