Skip to content

Commit

Permalink
chore: fix some comments
Browse files Browse the repository at this point in the history
Signed-off-by: peicuiping <[email protected]>
  • Loading branch information
peicuiping committed May 4, 2024
1 parent 987aa11 commit 94458de
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion libs/traits/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ pub mod benchmarking;
/// ## Overview
/// The crowdloan reward mechanism is separated from the crowdloan claiming
/// process, the latter being generic, acting as a kind of proxy to the
/// rewarding mechanism, that is specific to to each crowdloan campaign. The aim
/// rewarding mechanism, that is specific to each crowdloan campaign. The aim
/// of this pallet is to ensure that a claim for a reward payout is well-formed,
/// checking for replay attacks, spams or invalid claim (e.g. unknown
/// contributor, exceeding reward amount, ...).
Expand Down
2 changes: 1 addition & 1 deletion libs/traits/src/swaps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ pub trait Swaps<AccountId> {
) -> Result<SwapStatus<Self::Amount>, DispatchError>;

/// Cancel a swap partially or completely. The amount should be expressed in
/// the same currency as the the currency_out of the pending amount.
/// the same currency as the currency_out of the pending amount.
/// - If there was no previous swap, it errors outs.
/// - If there was a swap with other currency out, it errors outs.
/// - If there was a swap with same currency out:
Expand Down
2 changes: 1 addition & 1 deletion pallets/liquidity-pools/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -857,7 +857,7 @@ pub mod pallet {
Ok(general_index.index)
}

/// Returns the local currency identifier from from its general index.
/// Returns the local currency identifier from its general index.
///
/// Requires the currency to be registered in the `AssetRegistry`.
///
Expand Down
2 changes: 1 addition & 1 deletion pallets/pool-fees/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ pub mod pallet {
})
}

/// Return the the last fee id and bump it for the next query
/// Return the last fee id and bump it for the next query
pub(crate) fn generate_fee_id() -> Result<T::FeeId, ArithmeticError> {
LastFeeId::<T>::try_mutate(|last_fee_id| {
last_fee_id.ensure_add_assign(One::one())?;
Expand Down
2 changes: 1 addition & 1 deletion pallets/pool-system/src/solution.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ impl PoolState {
/// Removes an unhealthy state
///
/// * If the state was not present yet, it will not be removed,
/// it it was present if will be removed.
/// if it was present it will be removed.
///
/// * If there are no more unhealthy states, the state will
/// be switched to healthy
Expand Down
4 changes: 2 additions & 2 deletions pallets/pool-system/src/tranches.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2065,7 +2065,7 @@ pub mod test {
fn replace_tranche_less_interest_than_next_works() {
let mut tranches = default_tranches();

// ensure we have an interest rate lower than the the left side tranche with a
// ensure we have an interest rate lower than the left side tranche with a
// lower index, e.g. lower than 10% at index 1
let int_per_sec = Rate::one() / Rate::saturating_from_integer(SECS_PER_YEAR);
let min_risk_buffer = Perquintill::from_rational(4u64, 5);
Expand Down Expand Up @@ -2145,7 +2145,7 @@ pub mod test {
let mut tranches = default_tranches();

let min_risk_buffer = Perquintill::from_rational(4u64, 5);
// ensure we have an interest rate larger than the the right-side tranche with a
// ensure we have an interest rate larger than the right-side tranche with a
// greater index, e.g. larger than 5% at index 2
let int_per_sec = Rate::saturating_from_rational(6u64, 100)
/ Rate::saturating_from_integer(SECS_PER_YEAR)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ fn apply_and_check_session<T: Runtime>(
// The event exists in this list:
dbg!(frame_system::Pallet::<T>::events())
// But not in in this list (that is the implementation of find_event()),
// But not in this list (that is the implementation of find_event()),
// so try_into returns an Err for it.
dbg!(frame_system::Pallet::<T>::events()
.into_iter()
Expand Down

0 comments on commit 94458de

Please sign in to comment.