File tree 4 files changed +4
-5
lines changed
pallets/dapp-staking-migration/src
precompiles/dapp-staking-v3/src
4 files changed +4
-5
lines changed Original file line number Diff line number Diff line change 18
18
19
19
use super :: { Pallet as Migration , * } ;
20
20
21
- use sp_std:: vec;
22
21
use astar_primitives:: { dapp_staking:: SmartContractHandle , Balance } ;
23
22
use frame_benchmarking:: { account as benchmark_account, v2:: * } ;
24
23
use pallet_dapp_staking_v3:: StakeAmount ;
24
+ use sp_std:: vec;
25
25
26
26
fn smart_contract < T : Config > ( idx : u8 ) -> T :: SmartContract {
27
27
let address: T :: AccountId = benchmark_account ( "smart_contract" , idx. into ( ) , 456 ) ;
Original file line number Diff line number Diff line change @@ -553,7 +553,7 @@ where
553
553
// the entire amount from the origin to target contract.
554
554
//
555
555
// In case value comes from the past period, we don't care, since the `unstake` call will fall apart.
556
- let stake_amount = if staked_amount > 0
556
+ let amount = if staked_amount > 0
557
557
&& staked_amount. saturating_sub ( amount) < minimum_allowed_stake_amount
558
558
{
559
559
staked_amount
@@ -571,7 +571,7 @@ where
571
571
// Then call stake on the target smart contract
572
572
let stake_call = pallet_dapp_staking_v3:: Call :: < R > :: stake {
573
573
smart_contract : target_smart_contract,
574
- amount : stake_amount ,
574
+ amount,
575
575
} ;
576
576
RuntimeHelper :: < R > :: try_dispatch ( handle, Some ( origin) . into ( ) , stake_call) ?;
577
577
Original file line number Diff line number Diff line change @@ -768,7 +768,7 @@ fn nomination_transfer_is_ok() {
768
768
ExternalityBuilder :: build ( ) . execute_with ( || {
769
769
initialize ( ) ;
770
770
771
- // Register the first dApp, and stke on it.
771
+ // Register the first dApp, and stake on it.
772
772
let staker_h160 = ALICE ;
773
773
let staker_native = AddressMapper :: into_account_id ( staker_h160) ;
774
774
let smart_contract_address_1 = H160 :: repeat_byte ( 0xFA ) ;
Original file line number Diff line number Diff line change @@ -1379,7 +1379,6 @@ pub type Executive = frame_executive::Executive<
1379
1379
///
1380
1380
/// Once done, migrations should be removed from the tuple.
1381
1381
pub type Migrations =
1382
- // Part of shibuya-124
1383
1382
( pallet_dapp_staking_migration:: SingularStakingInfoTranslationUpgrade < Runtime > , ) ;
1384
1383
1385
1384
type EventRecord = frame_system:: EventRecord <
You can’t perform that action at this time.
0 commit comments