Skip to content

Commit

Permalink
merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
trinitys7 committed Sep 5, 2024
2 parents dbacb44 + 84d6b2a commit e0cddc5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions contracts/consumer/virtual-staking/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ impl VirtualStakingApi for VirtualStakingContract<'_> {
delegator,
validator: validator.clone(),
},
VirtualStakeMsg::Unbond { amount, validator }
VirtualStakeMsg::Unbond { amount, validator },
];
Ok(Response::new().add_messages(msgs))
}
Expand Down Expand Up @@ -595,7 +595,7 @@ impl VirtualStakingApi for VirtualStakingContract<'_> {
let all_delegations = TokenQuerier::new(&deps.querier)
.all_delegations(env.contract.address.to_string(), config.max_retrieve)?;
if all_delegations.delegations.len() == 0 {
return Ok(resp.add_message(VirtualStakeMsg::DeleteAllScheduledTasks{}));
return Ok(resp.add_message(VirtualStakeMsg::DeleteAllScheduledTasks {}));
}
let mut msgs = vec![];
for delegation in all_delegations.delegations {
Expand Down
2 changes: 1 addition & 1 deletion packages/bindings/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ pub enum VirtualStakeMsg {
validator: String,
},
/// Delete all scheduled tasks after zero max cap and unbond all delegations
DeleteAllScheduledTasks {}
DeleteAllScheduledTasks {},
}

impl VirtualStakeMsg {
Expand Down
4 changes: 3 additions & 1 deletion packages/virtual-staking-mock/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,9 @@ impl Module for VirtualStakingModule {
}
}
mesh_bindings::VirtualStakeMsg::UpdateDelegation { .. } => Ok(AppResponse::default()),
mesh_bindings::VirtualStakeMsg::DeleteAllScheduledTasks { } => Ok(AppResponse::default()),
mesh_bindings::VirtualStakeMsg::DeleteAllScheduledTasks { .. } => {
Ok(AppResponse::default())
}
}
}

Expand Down

0 comments on commit e0cddc5

Please sign in to comment.