Skip to content

Commit

Permalink
feat: fix main.rs clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
Evalir committed Mar 25, 2023
1 parent f948e7a commit c350a2f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ async fn main() -> Result<(), StdError> {
};

loop {
match context.beacon_api.get_block(None).await? {
Some(latest_beacon_block) => {
if let Some(latest_beacon_block) = context.beacon_api.get_block(None).await? {
let latest_slot: u32 = latest_beacon_block.slot.parse()?;

if current_slot < latest_slot {
Expand All @@ -38,7 +37,6 @@ async fn main() -> Result<(), StdError> {
current_slot = latest_slot;
}
}
_ => (),
};

thread::sleep(Duration::from_secs(1));
Expand Down

0 comments on commit c350a2f

Please sign in to comment.