Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
kariy committed Jul 16, 2024
1 parent c19e325 commit 74c5db1
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 13 deletions.
4 changes: 2 additions & 2 deletions bin/sozo/src/commands/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ pub enum Commands {
Init(InitArgs),
#[command(about = "Remove generated artifacts, manifests and abis")]
Clean(CleanArgs),
#[command(about = "Run a migration, declaring and deploying contracts as necessary to update \
the world")]
#[command(about = "Run a migration, declaring and deploying contracts as necessary to \
update the world")]
Migrate(Box<MigrateArgs>),
#[command(about = "Developer mode: watcher for building and migration")]
Dev(DevArgs),
Expand Down
12 changes: 2 additions & 10 deletions crates/katana/executor/src/implementation/blockifier/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,7 @@ impl<S: StateDb> ContractClassProvider for CachedState<S> {
return Ok(None);
};

if hash.0 == FieldElement::ZERO {
Ok(None)
} else {
Ok(Some(hash.0))
}
if hash.0 == FieldElement::ZERO { Ok(None) } else { Ok(Some(hash.0)) }
}

fn sierra_class(
Expand All @@ -163,11 +159,7 @@ impl<S: StateDb> StateProvider for CachedState<S> {
return Ok(None);
};

if hash.0 == FieldElement::ZERO {
Ok(None)
} else {
Ok(Some(hash.0))
}
if hash.0 == FieldElement::ZERO { Ok(None) } else { Ok(Some(hash.0)) }
}

fn nonce(
Expand Down
4 changes: 3 additions & 1 deletion crates/katana/storage/provider/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ pub enum ProviderError {

/// Error when a contract nonce change entry is not found but the block number of when the
/// change happen exists in the nonce change list.
#[error("Missing contract nonce change entry for contract {contract_address} at block {block}")]
#[error(
"Missing contract nonce change entry for contract {contract_address} at block {block}"
)]
MissingContractNonceChangeEntry {
/// The block number of when the change happen.
block: BlockNumber,
Expand Down

0 comments on commit 74c5db1

Please sign in to comment.