restore_ledger: TxDescriptor<{
    maybe_controller?: SS58String;
    maybe_total?: bigint;
    maybe_unlocking?: {
        era: number;
        value: bigint;
    }[];
    stash: SS58String;
}>

Restores the state of a ledger which is in an inconsistent state.

The requirements to restore a ledger are the following:

  • The stash is bonded; or
  • The stash is not bonded but it has a staking lock left behind; or
  • If the stash has an associated ledger and its state is inconsistent; or
  • If the ledger is not corrupted but its staking lock is out of sync.

The maybe_* input parameters will overwrite the corresponding data and metadata of the ledger associated with the stash. If the input parameters are not set, the ledger will be reset values from on-chain state.