diff --git a/pallets/distance/src/lib.rs b/pallets/distance/src/lib.rs index e97f8fade6cdd8521429f7ddef278c642ad4c7d2..d4b14b9180b61fb9e8dacaca9160a154a87b3f62 100644 --- a/pallets/distance/src/lib.rs +++ b/pallets/distance/src/lib.rs @@ -187,10 +187,10 @@ pub mod pallet { pub enum Error<T> { /// Distance is already under evaluation. AlreadyInEvaluation, - /// Author requests too many evaluations. - ManyEvaluationsByAuthor, + /// Too many evaluations requested by author. + TooManyEvaluationsByAuthor, /// Too many evaluations for this block. - ManyEvaluationsInBlock, + TooManyEvaluationsInBlock, /// No author for this block. NoAuthor, /// Caller has no identity. @@ -252,7 +252,7 @@ pub mod pallet { ensure_none(origin)?; ensure!( !DidUpdate::<T>::exists(), - Error::<T>::ManyEvaluationsInBlock, + Error::<T>::TooManyEvaluationsInBlock, ); let author = pallet_authorship::Pallet::<T>::author().ok_or(Error::<T>::NoAuthor)?; @@ -297,7 +297,7 @@ pub mod pallet { move |identities| { identities .try_push(identity) - .map_err(|_| Error::<T>::ManyEvaluationsInBlock) + .map_err(|_| Error::<T>::TooManyEvaluationsInBlock) }, )?; Self::deposit_event(Event::EvaluationStatusForced { @@ -323,7 +323,7 @@ pub mod pallet { move |identities| { identities .try_push(identity) - .map_err(|_| Error::<T>::ManyEvaluationsInBlock.into()) + .map_err(|_| Error::<T>::TooManyEvaluationsInBlock.into()) }, ) } @@ -453,7 +453,7 @@ pub mod pallet { Self::deposit_event(Event::EvaluationUpdated { evaluator }); Ok(()) } else { - Err(Error::<T>::ManyEvaluationsByAuthor.into()) + Err(Error::<T>::TooManyEvaluationsByAuthor.into()) } }) }