mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-07 00:42:42 +00:00
Address some review comments
This commit is contained in:
@@ -248,7 +248,7 @@ where
|
|||||||
.ok_or_else(|| "node timer requires a chain spec".to_string())?
|
.ok_or_else(|| "node timer requires a chain spec".to_string())?
|
||||||
.milliseconds_per_slot;
|
.milliseconds_per_slot;
|
||||||
|
|
||||||
let _ = timer::spawn(
|
timer::spawn_timer(
|
||||||
context.executor,
|
context.executor,
|
||||||
beacon_chain,
|
beacon_chain,
|
||||||
milliseconds_per_slot,
|
milliseconds_per_slot,
|
||||||
@@ -331,7 +331,7 @@ where
|
|||||||
.ok_or_else(|| "slot_notifier requires a chain spec".to_string())?
|
.ok_or_else(|| "slot_notifier requires a chain spec".to_string())?
|
||||||
.milliseconds_per_slot;
|
.milliseconds_per_slot;
|
||||||
|
|
||||||
let _ = spawn_notifier(
|
spawn_notifier(
|
||||||
context.executor,
|
context.executor,
|
||||||
beacon_chain,
|
beacon_chain,
|
||||||
network_globals,
|
network_globals,
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ use std::time::Duration;
|
|||||||
use tokio::time::{interval_at, Instant};
|
use tokio::time::{interval_at, Instant};
|
||||||
|
|
||||||
/// Spawns a timer service which periodically executes tasks for the beacon chain
|
/// Spawns a timer service which periodically executes tasks for the beacon chain
|
||||||
pub fn spawn<T: BeaconChainTypes>(
|
pub fn spawn_timer<T: BeaconChainTypes>(
|
||||||
executor: environment::TaskExecutor,
|
executor: environment::TaskExecutor,
|
||||||
beacon_chain: Arc<BeaconChain<T>>,
|
beacon_chain: Arc<BeaconChain<T>>,
|
||||||
milliseconds_per_slot: u64,
|
milliseconds_per_slot: u64,
|
||||||
|
|||||||
Reference in New Issue
Block a user