You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Store last FreeTransferCount free transfer time for each account
Module
impl OnReapAccount
clear LastFreeTransfers for reaped account
try_free_transfer(who: AccountId) -> bool
Read LastFreeTransfers, remove all the expired entries (value < now - FreeTransferPeriod), return true and append now to the list if entries count less than FreeTransferCount otherwise return false
ChargeTransactionPayment: SignedExtension
Similar to ChargeTransactionPayment in pallet-transaction-payment module
it additionaly call try_free_transfer and skip the withdraw fee part if the call is currencies.transfer and user still have free transfer
check pallet-contractsCheckBlockGasLimit for how to check call type
Use transaction_payment::ChargeTransactionPayment::from(tip)::compute_fee to reduce copy & paste
Update runtime to use the new ChargeTransactionPayment instead of the one in transaction payment module
We will still need additional requirements for an account to be able to make free transfer. This is still TBD.
The text was updated successfully, but these errors were encountered:
Accounts module
FreeTransferCount
free transfer time for each accountLastFreeTransfers
for reaped accountLastFreeTransfers
, remove all the expired entries (value < now - FreeTransferPeriod
), return true and appendnow
to the list if entries count less thanFreeTransferCount
otherwise return falseChargeTransactionPayment
inpallet-transaction-payment
moduletry_free_transfer
and skip the withdraw fee part if the call is currencies.transfer and user still have free transferpallet-contracts
CheckBlockGasLimit
for how to check call typetransaction_payment::ChargeTransactionPayment::from(tip)::compute_fee
to reduce copy & pasteUpdate runtime to use the new
ChargeTransactionPayment
instead of the one in transaction payment moduleWe will still need additional requirements for an account to be able to make free transfer. This is still TBD.
The text was updated successfully, but these errors were encountered: