Skip to content

Commit e93754b

Browse files
committed
fix typo
Signed-off-by: Jack Drogon <jack.xsuperman@gmail.com>
1 parent 9c6d516 commit e93754b

File tree

17 files changed

+56
-56
lines changed

17 files changed

+56
-56
lines changed

modules/collator-selection/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ pub mod pallet {
251251
#[pallet::event]
252252
#[pallet::generate_deposit(pub(super) fn deposit_event)]
253253
pub enum Event<T: Config> {
254-
/// Invulnurable was updated.
254+
/// Invulnerable was updated.
255255
NewInvulnerables { new_invulnerables: Vec<T::AccountId> },
256256
/// Desired candidates was updated.
257257
NewDesiredCandidates { new_desired_candidates: u32 },

modules/evm-accounts/src/lib.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -240,13 +240,13 @@ impl<T: Config> Pallet<T> {
240240

241241
fn evm_account_domain_separator() -> [u8; 32] {
242242
let domain_hash = keccak256!("EIP712Domain(string name,string version,uint256 chainId,bytes32 salt)");
243-
let mut domain_seperator_msg = domain_hash.to_vec();
244-
domain_seperator_msg.extend_from_slice(keccak256!("Acala EVM claim")); // name
245-
domain_seperator_msg.extend_from_slice(keccak256!("1")); // version
246-
domain_seperator_msg.extend_from_slice(&to_bytes(T::ChainId::get())); // chain id
247-
domain_seperator_msg
243+
let mut domain_separator_msg = domain_hash.to_vec();
244+
domain_separator_msg.extend_from_slice(keccak256!("Acala EVM claim")); // name
245+
domain_separator_msg.extend_from_slice(keccak256!("1")); // version
246+
domain_separator_msg.extend_from_slice(&to_bytes(T::ChainId::get())); // chain id
247+
domain_separator_msg
248248
.extend_from_slice(frame_system::Pallet::<T>::block_hash(BlockNumberFor::<T>::zero()).as_ref()); // genesis block hash
249-
keccak_256(domain_seperator_msg.as_slice())
249+
keccak_256(domain_separator_msg.as_slice())
250250
}
251251

252252
fn do_claim_default_evm_address(who: T::AccountId) -> Result<EvmAddress, DispatchError> {

modules/evm/src/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -719,14 +719,14 @@ pub mod module {
719719
ensure_root(origin)?;
720720

721721
let _from_account = T::AddressMapping::get_account_id(&from);
722-
let _payed: NegativeImbalanceOf<T>;
722+
let _paid: NegativeImbalanceOf<T>;
723723
#[cfg(not(feature = "with-ethereum-compatibility"))]
724724
{
725725
// unreserve the transaction fee for gas_limit
726726
let weight = T::GasToWeight::convert(gas_limit);
727727
let (_, imbalance) = T::ChargeTransactionPayment::unreserve_and_charge_fee(&_from_account, weight)
728728
.map_err(|_| Error::<T>::ChargeFeeFailed)?;
729-
_payed = imbalance;
729+
_paid = imbalance;
730730
}
731731

732732
match T::Runner::call(
@@ -786,7 +786,7 @@ pub mod module {
786786
let res = T::ChargeTransactionPayment::refund_fee(
787787
&_from_account,
788788
T::GasToWeight::convert(refund_gas),
789-
_payed,
789+
_paid,
790790
);
791791
debug_assert!(res.is_ok());
792792
}

modules/evm/src/runner/state.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1625,7 +1625,7 @@ impl<'inner, 'config, 'precompiles, S: StackState<'config>, P: PrecompileSet> Pr
16251625
self.executor.state.refund_external_cost(ref_time, proof_size);
16261626
}
16271627

1628-
/// Retreive the remaining gas.
1628+
/// Retrieve the remaining gas.
16291629
fn remaining_gas(&self) -> u64 {
16301630
self.executor.state.metadata().gasometer.gas()
16311631
}
@@ -1635,17 +1635,17 @@ impl<'inner, 'config, 'precompiles, S: StackState<'config>, P: PrecompileSet> Pr
16351635
Handler::log(self.executor, address, topics, data)
16361636
}
16371637

1638-
/// Retreive the code address (what is the address of the precompile being called).
1638+
/// Retrieve the code address (what is the address of the precompile being called).
16391639
fn code_address(&self) -> H160 {
16401640
self.code_address
16411641
}
16421642

1643-
/// Retreive the input data the precompile is called with.
1643+
/// Retrieve the input data the precompile is called with.
16441644
fn input(&self) -> &[u8] {
16451645
self.input
16461646
}
16471647

1648-
/// Retreive the context in which the precompile is executed.
1648+
/// Retrieve the context in which the precompile is executed.
16491649
fn context(&self) -> &Context {
16501650
self.context
16511651
}
@@ -1655,7 +1655,7 @@ impl<'inner, 'config, 'precompiles, S: StackState<'config>, P: PrecompileSet> Pr
16551655
self.is_static
16561656
}
16571657

1658-
/// Retreive the gas limit of this call.
1658+
/// Retrieve the gas limit of this call.
16591659
fn gas_limit(&self) -> Option<u64> {
16601660
self.gas_limit
16611661
}

modules/honzon/src/tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ fn transfer_debit_works() {
266266
HonzonModule::transfer_debit(RuntimeOrigin::signed(BOB), BTC, DOT, 1000),
267267
ArithmeticError::Underflow
268268
);
269-
// Won't work when transfering more debit than is present
269+
// Won't work when transferring more debit than is present
270270
assert_noop!(
271271
HonzonModule::transfer_debit(RuntimeOrigin::signed(ALICE), BTC, DOT, 10_000),
272272
ArithmeticError::Underflow

modules/prices/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
//! The data from Oracle cannot be used in business, prices module will do some
2424
//! process and feed prices for Acala. Process include:
2525
//! - specify a fixed price for stable currency
26-
//! - feed price in USD or related price bewteen two currencies
26+
//! - feed price in USD or related price between two currencies
2727
//! - lock/unlock the price data get from oracle
2828
2929
#![cfg_attr(not(feature = "std"), no_std)]

modules/support/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ pub trait TransactionPayment<AccountId, Balance, NegativeImbalance> {
120120
who: &AccountId,
121121
weight: Weight,
122122
) -> Result<(Balance, NegativeImbalance), TransactionValidityError>;
123-
fn refund_fee(who: &AccountId, weight: Weight, payed: NegativeImbalance) -> Result<(), TransactionValidityError>;
123+
fn refund_fee(who: &AccountId, weight: Weight, paid: NegativeImbalance) -> Result<(), TransactionValidityError>;
124124
fn charge_fee(
125125
who: &AccountId,
126126
len: u32,

modules/support/src/mocks.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ impl<AccountId, Balance: Default + Copy, NegativeImbalance: Imbalance<Balance>>
129129
fn refund_fee(
130130
_who: &AccountId,
131131
_weight: Weight,
132-
_payed: NegativeImbalance,
132+
_paid: NegativeImbalance,
133133
) -> Result<(), TransactionValidityError> {
134134
Ok(())
135135
}
@@ -188,7 +188,7 @@ impl<
188188
fn refund_fee(
189189
_who: &AccountId,
190190
_weight: Weight,
191-
_payed: NegativeImbalance,
191+
_paid: NegativeImbalance,
192192
) -> Result<(), TransactionValidityError> {
193193
Ok(())
194194
}

modules/transaction-payment/src/lib.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -306,10 +306,10 @@ pub mod module {
306306
/// transaction fee paid, the second is the tip paid, if any.
307307
type OnTransactionPayment: OnUnbalanced<NegativeImbalanceOf<Self>>;
308308

309-
/// A fee mulitplier for `Operational` extrinsics to compute "virtual tip" to boost their
309+
/// A fee multiplier for `Operational` extrinsics to compute "virtual tip" to boost their
310310
/// `priority`
311311
///
312-
/// This value is multipled by the `final_fee` to obtain a "virtual tip" that is later
312+
/// This value is multiplied by the `final_fee` to obtain a "virtual tip" that is later
313313
/// added to a tip component in regular `priority` calculations.
314314
/// It means that a `Normal` transaction can front-run a similarly-sized `Operational`
315315
/// extrinsic (with no tip), by including a tip value greater than the virtual tip.
@@ -371,19 +371,19 @@ pub mod module {
371371
/// Weight information for the extrinsics in this module.
372372
type WeightInfo: WeightInfo;
373373

374-
/// PalletId used to derivate sub account.
374+
/// PalletId used to derivative sub account.
375375
#[pallet::constant]
376376
type PalletId: Get<PalletId>;
377377

378378
/// Treasury account used to transfer balance to sub account of `PalletId`.
379379
#[pallet::constant]
380380
type TreasuryAccount: Get<Self::AccountId>;
381381

382-
/// Custom fee surplus if not payed with native asset.
382+
/// Custom fee surplus if not paid with native asset.
383383
#[pallet::constant]
384384
type CustomFeeSurplus: Get<Percent>;
385385

386-
/// Alternative fee surplus if not payed with native asset.
386+
/// Alternative fee surplus if not paid with native asset.
387387
#[pallet::constant]
388388
type AlternativeFeeSurplus: Get<Percent>;
389389

@@ -1462,7 +1462,7 @@ where
14621462
len: usize,
14631463
_result: &DispatchResult,
14641464
) -> Result<(), TransactionValidityError> {
1465-
if let Some((tip, who, Some(payed), fee, surplus)) = pre {
1465+
if let Some((tip, who, Some(paid), fee, surplus)) = pre {
14661466
let actual_fee = Pallet::<T>::compute_actual_fee(len as u32, info, post_info, tip);
14671467
let refund_fee = fee.saturating_sub(actual_fee);
14681468
let mut refund = refund_fee;
@@ -1489,7 +1489,7 @@ where
14891489

14901490
let actual_payment = match <T as Config>::Currency::deposit_into_existing(&who, refund) {
14911491
Ok(refund_imbalance) => {
1492-
// The refund cannot be larger than the up front payed max weight.
1492+
// The refund cannot be larger than the up front paid max weight.
14931493
// `PostDispatchInfo::calc_unspent` guards against such a case.
14941494
match payed.offset(refund_imbalance) {
14951495
SameOrOther::Same(actual_payment) => actual_payment,
@@ -1499,7 +1499,7 @@ where
14991499
}
15001500
// We do not recreate the account using the refund. The up front payment
15011501
// is gone in that case.
1502-
Err(_) => payed,
1502+
Err(_) => paid,
15031503
};
15041504
let (tip, fee) = actual_payment.split(actual_tip);
15051505

@@ -1570,14 +1570,14 @@ where
15701570
fn refund_fee(
15711571
who: &T::AccountId,
15721572
refund_weight: Weight,
1573-
payed: NegativeImbalanceOf<T>,
1573+
paid: NegativeImbalanceOf<T>,
15741574
) -> Result<(), TransactionValidityError> {
1575-
log::debug!(target: "transaction-payment", "refund_fee: who: {:?}, refund_weight: {:?}, payed: {:?}", who, refund_weight, payed.peek());
1575+
log::debug!(target: "transaction-payment", "refund_fee: who: {:?}, refund_weight: {:?}, paid: {:?}", who, refund_weight, payed.peek());
15761576

15771577
let refund = Pallet::<T>::weight_to_fee(refund_weight);
15781578
let actual_payment = match <T as Config>::Currency::deposit_into_existing(who, refund) {
15791579
Ok(refund_imbalance) => {
1580-
// The refund cannot be larger than the up front payed max weight.
1580+
// The refund cannot be larger than the up front paid max weight.
15811581
match payed.offset(refund_imbalance) {
15821582
SameOrOther::Same(actual_payment) => actual_payment,
15831583
SameOrOther::None => Default::default(),
@@ -1586,7 +1586,7 @@ where
15861586
}
15871587
// We do not recreate the account using the refund. The up front payment
15881588
// is gone in that case.
1589-
Err(_) => payed,
1589+
Err(_) => paid,
15901590
};
15911591

15921592
// distribute fee

modules/xcm-interface/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,8 @@ pub mod module {
195195
fn withdraw_unbonded_from_sub_account(sub_account_index: u16, amount: Balance) -> DispatchResult {
196196
let (xcm_dest_weight, xcm_fee) = Self::xcm_dest_weight_and_fee(XcmInterfaceOperation::HomaWithdrawUnbonded);
197197

198-
// TODO: config xcm_dest_weight and fee for withdraw_unbonded and transfer seperately.
199-
// Temperarily use double fee.
198+
// TODO: config xcm_dest_weight and fee for withdraw_unbonded and transfer separately.
199+
// Temporarily use double fee.
200200
let xcm_message = T::RelayChainCallBuilder::finalize_multiple_calls_into_xcm_message(
201201
vec![
202202
(

0 commit comments

Comments
 (0)