frame_system::remark: Allow any kind of origin (#14260)

* frame_system::remark: Allow any kind of origin

There should be no downside in allowing any kind of origin for `remark`.

* Fix tests
This commit is contained in:
Bastian Köcher
2023-06-04 23:15:16 +02:00
committed by GitHub
parent 643f8d76cd
commit 57e6b21935
3 changed files with 7 additions and 8 deletions
+2 -3
View File
@@ -414,11 +414,10 @@ pub mod pallet {
impl<T: Config> Pallet<T> {
/// Make some on-chain remark.
///
/// - `O(1)`
/// Can be executed by every `origin`.
#[pallet::call_index(0)]
#[pallet::weight(T::SystemWeightInfo::remark(_remark.len() as u32))]
pub fn remark(origin: OriginFor<T>, _remark: Vec<u8>) -> DispatchResultWithPostInfo {
ensure_signed_or_root(origin)?;
pub fn remark(_origin: OriginFor<T>, _remark: Vec<u8>) -> DispatchResultWithPostInfo {
Ok(().into())
}