Skip to content

Commit

Permalink
Remove expect
Browse files Browse the repository at this point in the history
  • Loading branch information
ferranbt committed Jan 2, 2025
1 parent f832c6f commit 1f8ea24
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions crates/rbuilder/src/live_builder/block_output/relay_submit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ async fn run_submit_to_relays_job(
slot_data.slot_data.pubkey,
block.trace.bid_value,
) {
Ok(res) => Some(res),
Ok(res) => Some((res, optimistic_config)),
Err(err) => {
error!(parent: &submission_span, err = ?err, "Error signing block for relay");
continue 'submit;
Expand Down Expand Up @@ -302,9 +302,9 @@ async fn run_submit_to_relays_job(
);
}

if let Some(optimistic_signed_submission) = &optimistic_signed_submission {
let optimistic_config = optimistic_config.expect("optimistic config is not None");

if let Some((optimistic_signed_submission, optimistic_config)) =
&optimistic_signed_submission
{
let can_submit = if optimistic_config.prevalidate_optimistic_blocks {
validate_block(
&slot_data,
Expand Down

0 comments on commit 1f8ea24

Please sign in to comment.