mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-08 09:16:00 +00:00
Fix warnings
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
use ethabi::{Contract, Token};
|
use ethabi::{Contract, Token};
|
||||||
use ssz::Encode;
|
use ssz::Encode;
|
||||||
use types::{DepositData, SecretKey};
|
use types::DepositData;
|
||||||
|
|
||||||
pub use ethabi::Error;
|
pub use ethabi::Error;
|
||||||
|
|
||||||
|
|||||||
@@ -74,14 +74,14 @@ impl SlotClock for SystemTimeSlotClock {
|
|||||||
genesis + slot * self.slot_duration
|
genesis + slot * self.slot_duration
|
||||||
};
|
};
|
||||||
|
|
||||||
let slot = self
|
let epoch_start_slot = self
|
||||||
.now()
|
.now()
|
||||||
.map(|slot| slot.epoch(slots_per_epoch))
|
.map(|slot| slot.epoch(slots_per_epoch))
|
||||||
.map(|epoch| (epoch + 1).start_slot(slots_per_epoch))?;
|
.map(|epoch| (epoch + 1).start_slot(slots_per_epoch))?;
|
||||||
|
|
||||||
if now >= genesis {
|
if now >= genesis {
|
||||||
Some(
|
Some(
|
||||||
slot_start(self.now()? + 1)
|
slot_start(epoch_start_slot)
|
||||||
.checked_sub(now)
|
.checked_sub(now)
|
||||||
.expect("The next epoch cannot start before now"),
|
.expect("The next epoch cannot start before now"),
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user