Skip to content

Commit

Permalink
also include approval data
Browse files Browse the repository at this point in the history
  • Loading branch information
findolor committed Feb 16, 2025
1 parent c2aef93 commit 9e44b05
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions crates/js_api/src/gui/order_operations.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,15 +165,15 @@ impl DotrainOrderGui {
) -> Result<ApprovalCalldataResult, GuiError> {
let deployment = self.get_current_deployment()?;
self.check_select_tokens()?;
self.check_deposits()?;

let deposits_map = self.get_deposits_as_map().await?;
if deposits_map.len() == 0 {
return Ok(ApprovalCalldataResult(Vec::new()));
}

let calldatas = self
.dotrain_order
.generate_approval_calldatas(
&deployment.key,
&owner,
&self.get_deposits_as_map().await?,
)
.generate_approval_calldatas(&deployment.key, &owner, &deposits_map)
.await?;
Ok(ApprovalCalldataResult(calldatas))
}
Expand Down

0 comments on commit 9e44b05

Please sign in to comment.