Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions frame/identity/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ decl_module! {

/// Add a registrar to the system.
///
/// The dispatch origin for this call must be `RegistrarOrigin` or `Root`.
/// The dispatch origin for this call must be `T::RegistrarOrigin`.
///
/// - `account`: the account of the registrar.
///
Expand Down Expand Up @@ -1087,7 +1087,7 @@ decl_module! {
/// `Slash`. Verification request deposits are not returned; they should be cancelled
/// manually using `cancel_request`.
///
/// The dispatch origin for this call must be _Root_ or match `T::ForceOrigin`.
/// The dispatch origin for this call must match `T::ForceOrigin`.
///
/// - `target`: the account whose identity the judgement is upon. This must be an account
/// with a registered identity.
Expand Down
12 changes: 8 additions & 4 deletions frame/membership/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ decl_module! {

/// Add a member `who` to the set.
///
/// May only be called from `AddOrigin` or root.
/// May only be called from `T::AddOrigin`.
#[weight = 50_000_000]
pub fn add_member(origin, who: T::AccountId) {
T::AddOrigin::ensure_origin(origin)?;
Expand All @@ -134,7 +134,7 @@ decl_module! {

/// Remove a member `who` from the set.
///
/// May only be called from `RemoveOrigin` or root.
/// May only be called from `T::RemoveOrigin`.
#[weight = 50_000_000]
pub fn remove_member(origin, who: T::AccountId) {
T::RemoveOrigin::ensure_origin(origin)?;
Expand All @@ -152,7 +152,7 @@ decl_module! {

/// Swap out one member `remove` for another `add`.
///
/// May only be called from `SwapOrigin` or root.
/// May only be called from `T::SwapOrigin`.
///
/// Prime membership is *not* passed from `remove` to `add`, if extant.
#[weight = 50_000_000]
Expand Down Expand Up @@ -181,7 +181,7 @@ decl_module! {
/// Change the membership to a new set, disregarding the existing membership. Be nice and
/// pass `members` pre-sorted.
///
/// May only be called from `ResetOrigin` or root.
/// May only be called from `T::ResetOrigin`.
#[weight = 50_000_000]
pub fn reset_members(origin, members: Vec<T::AccountId>) {
T::ResetOrigin::ensure_origin(origin)?;
Expand Down Expand Up @@ -231,6 +231,8 @@ decl_module! {
}

/// Set the prime member. Must be a current member.
///
/// May only be called from `T::PrimeOrigin`.
#[weight = 50_000_000]
pub fn set_prime(origin, who: T::AccountId) {
T::PrimeOrigin::ensure_origin(origin)?;
Expand All @@ -240,6 +242,8 @@ decl_module! {
}

/// Remove the prime member if it exists.
///
/// May only be called from `T::PrimeOrigin`.
#[weight = 50_000_000]
pub fn clear_prime(origin) {
T::PrimeOrigin::ensure_origin(origin)?;
Expand Down
4 changes: 2 additions & 2 deletions frame/nicks/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ decl_module! {
/// Fails if `who` has not been named. The deposit is dealt with through `T::Slashed`
/// imbalance handler.
///
/// The dispatch origin for this call must be _Root_ or match `T::ForceOrigin`.
/// The dispatch origin for this call must match `T::ForceOrigin`.
///
/// # <weight>
/// - O(1).
Expand All @@ -213,7 +213,7 @@ decl_module! {
///
/// No length checking is done on the name.
///
/// The dispatch origin for this call must be _Root_ or match `T::ForceOrigin`.
/// The dispatch origin for this call must match `T::ForceOrigin`.
///
/// # <weight>
/// - O(1).
Expand Down
4 changes: 2 additions & 2 deletions frame/scored-pool/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ decl_module! {

/// Kick a member `who` from the set.
///
/// May only be called from `KickOrigin` or root.
/// May only be called from `T::KickOrigin`.
///
/// The `index` parameter of this function must be set to
/// the index of `dest` in the `Pool`.
Expand All @@ -331,7 +331,7 @@ decl_module! {

/// Score a member `who` with `score`.
///
/// May only be called from `ScoreOrigin` or root.
/// May only be called from `T::ScoreOrigin`.
///
/// The `index` parameter of this function must be set to
/// the index of the `dest` in the `Pool`.
Expand Down
2 changes: 1 addition & 1 deletion frame/staking/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1928,7 +1928,7 @@ decl_module! {

/// Cancel enactment of a deferred slash.
///
/// Can be called by either the root origin or the `T::SlashCancelOrigin`.
/// Can be called by the `T::SlashCancelOrigin`.
///
/// Parameters: era and indices of the slashes for that era to kill.
///
Expand Down
6 changes: 5 additions & 1 deletion frame/treasury/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ decl_module! {

/// The amount held on deposit per byte within the tip report reason.
const TipReportDepositPerByte: BalanceOf<T> = T::TipReportDepositPerByte::get();

/// The treasury's module id, used for deriving its sovereign account ID.
const ModuleId: ModuleId = T::ModuleId::get();

Expand Down Expand Up @@ -355,6 +355,8 @@ decl_module! {

/// Reject a proposed spend. The original deposit will be slashed.
///
/// May only be called from `T::RejectOrigin`.
///
/// # <weight>
/// - Complexity: O(1)
/// - DbReads: `Proposals`, `rejected proposer account`
Expand All @@ -375,6 +377,8 @@ decl_module! {
/// Approve a proposal. At a later time, the proposal will be allocated to the beneficiary
/// and the original deposit will be returned.
///
/// May only be called from `T::ApproveOrigin`.
///
/// # <weight>
/// - Complexity: O(1).
/// - DbReads: `Proposals`, `Approvals`
Expand Down