Skip to content

Commit

Permalink
handle success case first
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeldjeffrey committed Dec 3, 2024
1 parent 3f285f8 commit 6edd596
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions mobile_packet_verifier/src/burner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,16 @@ where
tracing::info!(%total_dcs, %payer, "Burning DC");
let txn = self.solana.make_burn_transaction(&payer, total_dcs).await?;
match self.solana.submit_transaction(&txn).await {
Ok(()) => {
handle_transaction_success(
pool,
payer,
total_dcs,
sessions,
&self.valid_sessions,
)
.await?;
}
Err(err) => {
let span = tracing::info_span!(
"txn_confirmation",
Expand All @@ -73,16 +83,6 @@ where
.instrument(span),
);
}
Ok(()) => {
handle_transaction_success(
pool,
payer,
total_dcs,
sessions,
&self.valid_sessions,
)
.await?;
}
}
}

Expand Down

0 comments on commit 6edd596

Please sign in to comment.