Skip to content

Commit

Permalink
fix: clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
glihm committed Nov 7, 2023
1 parent 5f00238 commit 5444b56
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/declare.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,8 @@ pub fn lua_declare<'lua>(
Ok((class_hash, decl_res)) => {
// If the declaration is skipped due to already declared class,
// we don't have any transaction hash.
let transaction_hash = if let Some(res) = decl_res {
Some(format!("0x{:064x}", res.transaction_hash))
} else {
None
};
let transaction_hash =
decl_res.map(|res| format!("0x{:064x}", res.transaction_hash));

LuaOutput {
data: Some(DeclareOutput {
Expand Down

0 comments on commit 5444b56

Please sign in to comment.