mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-22 06:14:38 +00:00
Change seconds_per_slot to milliseconds_per_slot
This commit is contained in:
@@ -151,7 +151,7 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
let slot_clock = T::SlotClock::from_eth2_genesis(
|
||||
spec.genesis_slot,
|
||||
genesis_state.genesis_time,
|
||||
Duration::from_secs(spec.seconds_per_slot),
|
||||
Duration::from_millis(spec.milliseconds_per_slot),
|
||||
)
|
||||
.ok_or_else(|| Error::SlotClockDidNotStart)?;
|
||||
|
||||
@@ -184,7 +184,7 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
let slot_clock = T::SlotClock::from_eth2_genesis(
|
||||
spec.genesis_slot,
|
||||
p.state.genesis_time,
|
||||
Duration::from_secs(spec.seconds_per_slot),
|
||||
Duration::from_millis(spec.milliseconds_per_slot),
|
||||
)
|
||||
.ok_or_else(|| Error::SlotClockDidNotStart)?;
|
||||
|
||||
@@ -397,17 +397,6 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/// Returns slot of the present state.
|
||||
///
|
||||
/// This is distinct to `read_slot_clock`, which reads from the actual system clock. If
|
||||
/// `self.state` has not been transitioned it is possible for the system clock to be on a
|
||||
/// different slot to what is returned from this call.
|
||||
pub fn present_slot(&self) -> Slot {
|
||||
self.state.read().slot
|
||||
}
|
||||
*/
|
||||
|
||||
/// Returns the block proposer for a given slot.
|
||||
///
|
||||
/// Information is read from the present `beacon_state` shuffling, only information from the
|
||||
|
||||
Reference in New Issue
Block a user