Skip to content

Commit

Permalink
Add rewards routing comments
Browse files Browse the repository at this point in the history
Co-authored-by: Runchao Han <[email protected]>
  • Loading branch information
2 people authored and Mauro Lacy committed Jan 29, 2025
1 parent 0711c85 commit 2497493
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions contracts/btc-finality/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,8 @@ fn send_rewards_msg(
})
.collect::<StdResult<Vec<_>>>()?;
let wasm_msg = if recipient == cfg.babylon {
// The rewards are sent to the Babylon contract, and the Babylon
// contract will send the rewards to the Babylon chain for distribution
let msg = babylon_contract::ExecuteMsg::SendRewards {
fp_distribution: fp_rewards.clone(),
};
Expand All @@ -337,6 +339,7 @@ fn send_rewards_msg(
funds: coins(rewards, cfg.denom.as_str()),
}
} else if recipient == cfg.staking {
// The rewards are sent to the BTC staking contract for distribution
let msg = btc_staking::msg::ExecuteMsg::DistributeRewards {
fp_distribution: fp_rewards.clone(),
};
Expand Down

0 comments on commit 2497493

Please sign in to comment.