Amend staking docs to account for state of controller deprecation (#2451)

Amends some staking pallet docs, and deprecation comment, to adjust to
the latest controller deprecation state.

Note, do we need the `README.md` file, which is a duplicate of the
pallet docs? Docs would be easier to maintain, and less ambiguity for
devs to refer to, if we had one source of truth in the generated pallet
docs.
This commit is contained in:
Ross Bulat
2023-11-24 00:14:59 +07:00
committed by GitHub
parent 19c05e8d43
commit c29b74dc36
3 changed files with 50 additions and 57 deletions
+1 -1
View File
@@ -359,7 +359,7 @@ impl<T: Config> Pallet<T> {
#[allow(deprecated)]
RewardDestination::Controller => Self::bonded(stash)
.map(|controller| {
defensive!("Paying out controller as reward destination which is deprecated and should be migrated");
defensive!("Paying out controller as reward destination which is deprecated and should be migrated.");
// This should never happen once payees with a `Controller` variant have been migrated.
// But if it does, just pay the controller account.
T::Currency::deposit_creating(&controller, amount)