Skip to content

Commit

Permalink
chore: return message sequence in mock dapp send call
Browse files Browse the repository at this point in the history
  • Loading branch information
bishalbikram committed May 17, 2024
1 parent cf835ce commit 153f225
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions contracts/soroban/contracts/mock-dapp-multi/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl MockDapp {
msg_type: u32,
rollback: Option<Bytes>,
sender: Address,
) -> Result<(), ContractError> {
) -> Result<u128, ContractError> {
sender.require_auth();

let network_id = to.nid(&env);
Expand All @@ -48,9 +48,9 @@ impl MockDapp {
};

let xcall_address = Self::get_xcall_address(&env)?;
Self::xcall_send_call(&env, &sender, &to, &envelope, &xcall_address);
let res = Self::xcall_send_call(&env, &sender, &to, &envelope, &xcall_address);

Ok(())
Ok(res)
}

pub fn handle_call_message(
Expand Down
4 changes: 2 additions & 2 deletions contracts/soroban/contracts/mock-dapp-multi/src/xcall.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ impl MockDapp {
to: &NetworkAddress,
envelope: &Envelope,
xcall_address: &Address,
) {
) -> u128 {
let client = XcallClient::new(&e, &xcall_address);
client.send_call(
sender,
&e.current_contract_address(),
envelope,
&to.to_string(),
);
)
}

pub fn xcall_get_fee(
Expand Down

0 comments on commit 153f225

Please sign in to comment.