Use explicit call indices (#12891)

* frame-system: explicit call index

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Use explicit call indices

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* pallet-template: explicit call index

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* DNM: Temporarily require call_index

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Revert "DNM: Temporarily require call_index"

This reverts commit c4934e312e12af72ca05a8029d7da753a9c99346.

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
Oliver Tale-Yazdi
2022-12-12 15:32:41 +01:00
committed by GitHub
parent 6e0453a298
commit 31f5119ecd
67 changed files with 403 additions and 0 deletions
+3
View File
@@ -403,6 +403,7 @@ pub mod pallet {
/// the equivocation proof and validate the given key ownership proof
/// against the extracted offender. If both are valid, the offence will
/// be reported.
#[pallet::call_index(0)]
#[pallet::weight(<T as Config>::WeightInfo::report_equivocation(
key_owner_proof.validator_count(),
))]
@@ -424,6 +425,7 @@ pub mod pallet {
/// block authors will call it (validated in `ValidateUnsigned`), as such
/// if the block author is defined it will be defined as the equivocation
/// reporter.
#[pallet::call_index(1)]
#[pallet::weight(<T as Config>::WeightInfo::report_equivocation(
key_owner_proof.validator_count(),
))]
@@ -445,6 +447,7 @@ pub mod pallet {
/// the next call to `enact_epoch_change`. The config will be activated one epoch after.
/// Multiple calls to this method will replace any existing planned config change that had
/// not been enacted yet.
#[pallet::call_index(2)]
#[pallet::weight(<T as Config>::WeightInfo::plan_config_change())]
pub fn plan_config_change(
origin: OriginFor<T>,