Skip to content

Commit

Permalink
style: cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosvdr committed Jan 24, 2025
1 parent a4bb78a commit d33ce55
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
5 changes: 2 additions & 3 deletions crates/service/src/routes/request_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,8 @@ pub async fn request_handler(

let attestable = response
.headers()
.get(GRAPH_ATTESTABLE).is_some_and(|value| {
value.to_str().map(|value| value == "true").unwrap_or(false)
});
.get(GRAPH_ATTESTABLE)
.is_some_and(|value| value.to_str().map(|value| value == "true").unwrap_or(false));

let graph_indexed = response.headers().get(GRAPH_INDEXED).cloned();
let body = response
Expand Down
3 changes: 2 additions & 1 deletion crates/service/src/tap/checks/sender_balance_check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ impl Check for SenderBalanceCheck {
// Check that the sender has a non-zero balance -- more advanced accounting is done in
// `tap-agent`.
if !escrow_accounts_snapshot
.get_balance_for_sender(receipt_sender).is_ok_and(|balance| balance > U256::ZERO)
.get_balance_for_sender(receipt_sender)
.is_ok_and(|balance| balance > U256::ZERO)
{
return Err(CheckError::Failed(anyhow!(
"Receipt sender `{}` does not have a sufficient balance",
Expand Down
6 changes: 4 additions & 2 deletions crates/tap-agent/src/tap/context/receipt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,8 @@ mod test {
.signed_receipt()
.recover_signer(&TAP_EIP712_DOMAIN_SEPARATOR)
.unwrap(),
).is_ok_and(|v| v == storage_adapter.sender)
)
.is_ok_and(|v| v == storage_adapter.sender)
})
.cloned()
.collect();
Expand Down Expand Up @@ -345,7 +346,8 @@ mod test {
.signed_receipt()
.recover_signer(&TAP_EIP712_DOMAIN_SEPARATOR)
.unwrap(),
).is_ok_and(|v| v == storage_adapter.sender)
)
.is_ok_and(|v| v == storage_adapter.sender)
{
!range.contains(&received_receipt.signed_receipt().message.timestamp_ns)
} else {
Expand Down

0 comments on commit d33ce55

Please sign in to comment.