Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
Larkooo committed Jun 3, 2024
1 parent daa85fa commit 0679518
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions crates/dojo-bindgen/src/plugins/unity/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ public class {} : ModelInstance {{
handled_tokens: &[Composite],
) -> String {
let mapped_type = UnityPlugin::map_type(token);

match handled_tokens.iter().find(|t| t.type_name() == token.type_name()) {
Some(t) => {
// Need to flatten the struct members.
Expand Down Expand Up @@ -269,7 +269,7 @@ public class {} : ModelInstance {{
None => match mapped_type.as_str() {
"FieldElement" => format!("calldata.Add({}.Inner);", type_name),
_ => format!("calldata.Add(new FieldElement({}).Inner);", type_name),
}
},
}
}

Expand All @@ -283,9 +283,7 @@ public class {} : ModelInstance {{
let calldata = system
.inputs
.iter()
.map(|(name, token)| {
handle_arg_recursive(name, token, handled_tokens)
})
.map(|(name, token)| handle_arg_recursive(name, token, handled_tokens))
.collect::<Vec<String>>()
.join("\n\t\t");

Expand Down

0 comments on commit 0679518

Please sign in to comment.