Skip to content

Commit

Permalink
feat: add burn_from_address arg to submit_burn_tokens method
Browse files Browse the repository at this point in the history
  • Loading branch information
NeverHappened committed Aug 2, 2024
1 parent 6e7e83d commit a5ca448
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/neutron-sdk/src/bindings/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -432,11 +432,16 @@ impl NeutronMsg {
/// Basic helper to define burn tokens passed to TokenFactory module:
/// * **denom** is a name of the denom;
/// * **amount** is an amount of tokens to burn.
pub fn submit_burn_tokens(denom: impl Into<String>, amount: Uint128) -> Self {
/// * **burn_from_address** is an address tokens will be burned from
pub fn submit_burn_tokens(
denom: impl Into<String>,
amount: Uint128,
burn_from_address: Option<String>,
) -> Self {
NeutronMsg::BurnTokens {
denom: denom.into(),
amount,
burn_from_address: String::new(),
burn_from_address: burn_from_address.unwrap_or_default(),
}
}

Expand Down

0 comments on commit a5ca448

Please sign in to comment.