From 02aecb56fe0ed42b98ceee7f270da1b1ed972e90 Mon Sep 17 00:00:00 2001
From: Hugo Trentesaux <hugo@trentesaux.fr>
Date: Wed, 17 Jan 2024 13:54:26 +0100
Subject: [PATCH] add points in docstrings

---
 docs/api/runtime-errors.md           |  34 +++++++++++++--------------
 docs/api/runtime-events.md           |  10 ++++----
 pallets/authority-members/src/lib.rs |  18 +++++++-------
 pallets/certification/src/lib.rs     |  31 ++++++++++++------------
 pallets/distance/src/lib.rs          |   8 +++----
 pallets/duniter-wot/src/lib.rs       |  10 ++++----
 pallets/identity/src/lib.rs          |   6 ++---
 pallets/membership/src/lib.rs        |   2 +-
 pallets/smith-members/src/lib.rs     |   6 ++---
 resources/metadata.scale             | Bin 128437 -> 128457 bytes
 10 files changed, 62 insertions(+), 63 deletions(-)

diff --git a/docs/api/runtime-errors.md b/docs/api/runtime-errors.md
index a93c10f6f..620c1674c 100644
--- a/docs/api/runtime-errors.md
+++ b/docs/api/runtime-errors.md
@@ -386,21 +386,21 @@ A smith has a limited stock of certifications
 <details>
 <summary>
 <code>AlreadyIncoming</code> - 0</summary>
-Member already incoming
+Member already incoming.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>AlreadyOnline</code> - 1</summary>
-Member already online
+Member already online.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>AlreadyOutgoing</code> - 2</summary>
-Member already outgoing
+Member already outgoing.
 </details>
 </li>
 <li>
@@ -414,42 +414,42 @@ Owner key is invalid as a member.
 <details>
 <summary>
 <code>MemberBlacklisted</code> - 4</summary>
-Member is blacklisted
+Member is blacklisted.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>MemberNotBlacklisted</code> - 5</summary>
-Member is not blacklisted
+Member is not blacklisted.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>MemberNotFound</code> - 6</summary>
-Member not found
+Member not found.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>NotOnlineNorIncoming</code> - 7</summary>
-Neither online nor scheduled
+Neither online nor scheduled.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>NotMember</code> - 8</summary>
-Not member
+Not member.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>SessionKeysNotProvided</code> - 9</summary>
-Session keys not provided
+Session keys not provided.
 </details>
 </li>
 <li>
@@ -741,14 +741,14 @@ This account is not allowed to claim UDs.
 <details>
 <summary>
 <code>NotEnoughCerts</code> - 0</summary>
-Insufficient certifications received
+Insufficient certifications received.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>TargetStatusInvalid</code> - 1</summary>
-Target status is incompatible with this operation
+Target status is incompatible with this operation.
 </details>
 </li>
 <li>
@@ -790,7 +790,7 @@ Issuer or receiver not found.
 <details>
 <summary>
 <code>MembershipRenewalPeriodNotRespected</code> - 7</summary>
-Membership can only be renewed after an antispam delay
+Membership can only be renewed after an antispam delay.
 </details>
 </li>
 </ul>
@@ -959,7 +959,7 @@ Membership not found.
 <details>
 <summary>
 <code>AlreadyMember</code> - 3</summary>
-Already member, can not claim membership
+Already member, can not claim membership.
 </details>
 </li>
 </ul>
@@ -970,21 +970,21 @@ Already member, can not claim membership
 <details>
 <summary>
 <code>CannotCertifySelf</code> - 0</summary>
-Identity cannot certify itself
+Identity cannot certify itself.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>IssuedTooManyCert</code> - 1</summary>
-Identity has already issued the maximum number of certifications
+Identity has already issued the maximum number of certifications.
 </details>
 </li>
 <li>
 <details>
 <summary>
 <code>IssuerNotFound</code> - 2</summary>
-Issuer not found
+Issuer not found.
 </details>
 </li>
 <li>
@@ -1093,7 +1093,7 @@ Evaluation result has a wrong length.
 <details>
 <summary>
 <code>TargetMustBeUnvalidated</code> - 12</summary>
-Targeted distance evaluation request is only possible for an unvalidated identity
+Targeted distance evaluation request is only possible for an unvalidated identity.
 </details>
 </li>
 </ul>
diff --git a/docs/api/runtime-events.md b/docs/api/runtime-events.md
index c495670a1..566e73839 100644
--- a/docs/api/runtime-events.md
+++ b/docs/api/runtime-events.md
@@ -650,7 +650,7 @@ no args
 <details>
 <summary>
 <code>InvitationSent(idty_index, invited_by)</code> - 0</summary>
-An identity is being inivited to become a smith
+An identity is being inivited to become a smith.
 
 ```rust
 idty_index: T::IdtyIndex
@@ -663,7 +663,7 @@ invited_by: T::IdtyIndex
 <details>
 <summary>
 <code>InvitationAccepted(idty_index)</code> - 1</summary>
-The invitation has been accepted
+The invitation has been accepted.
 
 ```rust
 idty_index: T::IdtyIndex
@@ -700,7 +700,7 @@ idty_index: T::IdtyIndex
 <details>
 <summary>
 <code>SmithExcluded(idty_index)</code> - 4</summary>
-A smith has been removed from the smiths set
+A smith has been removed from the smiths set.
 
 ```rust
 idty_index: T::IdtyIndex
@@ -1374,7 +1374,7 @@ who: T::AccountId
 <details>
 <summary>
 <code>EvaluatedValid(idty_index)</code> - 1</summary>
-Distance rule was found valid
+Distance rule was found valid.
 
 ```rust
 idty_index: T::IdtyIndex
@@ -1386,7 +1386,7 @@ idty_index: T::IdtyIndex
 <details>
 <summary>
 <code>EvaluatedInvalid(idty_index)</code> - 2</summary>
-Distance rule was found invalid
+Distance rule was found invalid.
 
 ```rust
 idty_index: T::IdtyIndex
diff --git a/pallets/authority-members/src/lib.rs b/pallets/authority-members/src/lib.rs
index d4ebf6b3f..3494331ad 100644
--- a/pallets/authority-members/src/lib.rs
+++ b/pallets/authority-members/src/lib.rs
@@ -177,25 +177,25 @@ pub mod pallet {
 
     #[pallet::error]
     pub enum Error<T> {
-        /// Member already incoming
+        /// Member already incoming.
         AlreadyIncoming,
-        /// Member already online
+        /// Member already online.
         AlreadyOnline,
-        /// Member already outgoing
+        /// Member already outgoing.
         AlreadyOutgoing,
         /// Owner key is invalid as a member.
         MemberIdNotFound,
-        /// Member is blacklisted
+        /// Member is blacklisted.
         MemberBlacklisted,
-        /// Member is not blacklisted
+        /// Member is not blacklisted.
         MemberNotBlacklisted,
-        /// Member not found
+        /// Member not found.
         MemberNotFound,
-        /// Neither online nor scheduled
+        /// Neither online nor scheduled.
         NotOnlineNorIncoming,
-        /// Not member
+        /// Not member.
         NotMember,
-        /// Session keys not provided
+        /// Session keys not provided.
         SessionKeysNotProvided,
         /// Too many authorities.
         TooManyAuthorities,
diff --git a/pallets/certification/src/lib.rs b/pallets/certification/src/lib.rs
index cd09e397a..f3cc3c0c4 100644
--- a/pallets/certification/src/lib.rs
+++ b/pallets/certification/src/lib.rs
@@ -58,7 +58,7 @@ pub mod pallet {
     #[pallet::config]
     pub trait Config: frame_system::Config {
         #[pallet::constant]
-        /// Minimum duration between two certifications issued by the same issuer
+        /// Minimum duration between two certifications issued by the same issuer.
         type CertPeriod: Get<Self::BlockNumber>;
         /// A short identity index.
         type IdtyIndex: Parameter
@@ -70,27 +70,26 @@ pub mod pallet {
             + MaybeSerializeDeserialize
             + Debug
             + MaxEncodedLen;
-        /// Something that give the owner key of an identity
+        /// Something that give the owner key of an identity.
         type OwnerKeyOf: Convert<Self::IdtyIndex, Option<Self::AccountId>>;
-        ///
+        /// Provide method to check that cert is allowed.
         type CheckCertAllowed: CheckCertAllowed<Self::IdtyIndex>;
         #[pallet::constant]
-        /// Maximum number of active certifications by issuer
+        /// Maximum number of active certifications by issuer.
         type MaxByIssuer: Get<u32>;
-        /// Minimum number of certifications that must be received to be able to issue
-        /// certifications.
+        /// Minimum number of certifications received to be allowed to issue a certification.
         #[pallet::constant]
         type MinReceivedCertToBeAbleToIssueCert: Get<u32>;
-        /// Handler for NewCert event
+        /// Handler for NewCert event.
         type OnNewcert: OnNewcert<Self::IdtyIndex>;
-        /// Handler for Removed event
+        /// Handler for Removed event.
         type OnRemovedCert: OnRemovedCert<Self::IdtyIndex>;
         /// Because this pallet emits events, it depends on the runtime's definition of an event.
         type RuntimeEvent: From<Event<Self>> + IsType<<Self as frame_system::Config>::RuntimeEvent>;
-        /// Type representing the weight of this pallet
+        /// Type representing the weight of this pallet.
         type WeightInfo: WeightInfo;
         #[pallet::constant]
-        /// Duration of validity of a certification
+        /// Duration of validity of a certification.
         type ValidityPeriod: Get<Self::BlockNumber>;
     }
 
@@ -200,19 +199,19 @@ pub mod pallet {
 
     // STORAGE //
 
-    /// Certifications metada by issuer
+    /// Certifications metada by issuer.
     #[pallet::storage]
     #[pallet::getter(fn idty_cert_meta)]
     pub type StorageIdtyCertMeta<T: Config> =
         StorageMap<_, Twox64Concat, T::IdtyIndex, IdtyCertMeta<T::BlockNumber>, ValueQuery>;
 
-    /// Certifications by receiver
+    /// Certifications by receiver.
     #[pallet::storage]
     #[pallet::getter(fn certs_by_receiver)]
     pub type CertsByReceiver<T: Config> =
         StorageMap<_, Twox64Concat, T::IdtyIndex, Vec<(T::IdtyIndex, T::BlockNumber)>, ValueQuery>;
 
-    /// Certifications removable on
+    /// Certifications removable on.
     #[pallet::storage]
     #[pallet::getter(fn certs_removable_on)]
     pub type CertsRemovableOn<T: Config> =
@@ -245,11 +244,11 @@ pub mod pallet {
 
     #[pallet::error]
     pub enum Error<T> {
-        /// Identity cannot certify itself
+        /// Identity cannot certify itself.
         CannotCertifySelf,
-        /// Identity has already issued the maximum number of certifications
+        /// Identity has already issued the maximum number of certifications.
         IssuedTooManyCert,
-        /// Issuer not found
+        /// Issuer not found.
         IssuerNotFound,
         /// Insufficient certifications received.
         NotEnoughCertReceived,
diff --git a/pallets/distance/src/lib.rs b/pallets/distance/src/lib.rs
index cbfa3e9ef..1790134a0 100644
--- a/pallets/distance/src/lib.rs
+++ b/pallets/distance/src/lib.rs
@@ -167,9 +167,9 @@ pub mod pallet {
             idty_index: T::IdtyIndex,
             who: T::AccountId,
         },
-        /// Distance rule was found valid
+        /// Distance rule was found valid.
         EvaluatedValid { idty_index: T::IdtyIndex },
-        /// Distance rule was found invalid
+        /// Distance rule was found invalid.
         EvaluatedInvalid { idty_index: T::IdtyIndex },
     }
 
@@ -191,7 +191,7 @@ pub mod pallet {
         CallerIdentityNotFound,
         /// Caller not member.
         CallerNotMember,
-        // Caller status can only be Unvalidated, Member or NotMember
+        // Caller status can only be Unvalidated, Member or NotMember.
         CallerStatusInvalid,
         /// Target identity not found.
         TargetIdentityNotFound,
@@ -201,7 +201,7 @@ pub mod pallet {
         TooManyEvaluators,
         /// Evaluation result has a wrong length.
         WrongResultLength,
-        /// Targeted distance evaluation request is only possible for an unvalidated identity
+        /// Targeted distance evaluation request is only possible for an unvalidated identity.
         TargetMustBeUnvalidated,
     }
 
diff --git a/pallets/duniter-wot/src/lib.rs b/pallets/duniter-wot/src/lib.rs
index 67961a5a1..7051c922c 100644
--- a/pallets/duniter-wot/src/lib.rs
+++ b/pallets/duniter-wot/src/lib.rs
@@ -83,11 +83,11 @@ pub mod pallet {
 
     #[pallet::error]
     pub enum Error<T> {
-        /// Insufficient certifications received
+        /// Insufficient certifications received.
         NotEnoughCerts,
-        /// Target status is incompatible with this operation
-        // Membership can not be added/renewed with this status
-        // Certification can not be added to identity with this status
+        /// Target status is incompatible with this operation.
+        // - Membership can not be added/renewed with this status
+        // - Certification can not be added to identity with this status
         TargetStatusInvalid,
         /// Identity creation period not respected.
         IdtyCreationPeriodNotRespected,
@@ -99,7 +99,7 @@ pub mod pallet {
         IssuerNotMember,
         /// Issuer or receiver not found.
         IdtyNotFound,
-        /// Membership can only be renewed after an antispam delay
+        /// Membership can only be renewed after an antispam delay.
         MembershipRenewalPeriodNotRespected,
     }
 }
diff --git a/pallets/identity/src/lib.rs b/pallets/identity/src/lib.rs
index 01998e0c5..dbe7167c5 100644
--- a/pallets/identity/src/lib.rs
+++ b/pallets/identity/src/lib.rs
@@ -82,18 +82,18 @@ pub mod pallet {
         /// Period after which a revoked identity is removed and the keys are freed.
         #[pallet::constant]
         type DeletionPeriod: Get<Self::BlockNumber>;
-        /// Minimum duration between two owner key changes
+        /// Minimum duration between two owner key changes.
         // to avoid stealing the identity without means to revoke
         #[pallet::constant]
         type ChangeOwnerKeyPeriod: Get<Self::BlockNumber>;
-        /// Minimum duration between the creation of 2 identities by the same creator
+        /// Minimum duration between the creation of 2 identities by the same creator.
         // it should be greater or equal than the certification period in certification pallet
         #[pallet::constant]
         type IdtyCreationPeriod: Get<Self::BlockNumber>;
         /// Management of the authorizations of the different calls.
         /// The default implementation allows everything.
         type CheckIdtyCallAllowed: CheckIdtyCallAllowed<Self>;
-        /// Custom data to store in each identity
+        /// Custom data to store in each identity.
         type IdtyData: Clone
             + Codec
             + Default
diff --git a/pallets/membership/src/lib.rs b/pallets/membership/src/lib.rs
index f0c463750..c23c07a86 100644
--- a/pallets/membership/src/lib.rs
+++ b/pallets/membership/src/lib.rs
@@ -181,7 +181,7 @@ pub mod pallet {
         MembershipAlreadyAcquired,
         /// Membership not found.
         MembershipNotFound,
-        /// Already member, can not claim membership
+        /// Already member, can not claim membership.
         AlreadyMember,
     }
 
diff --git a/pallets/smith-members/src/lib.rs b/pallets/smith-members/src/lib.rs
index 95dd31177..8d4df3fa6 100644
--- a/pallets/smith-members/src/lib.rs
+++ b/pallets/smith-members/src/lib.rs
@@ -128,12 +128,12 @@ pub mod pallet {
     #[pallet::event]
     #[pallet::generate_deposit(pub(super) fn deposit_event)]
     pub enum Event<T: Config> {
-        /// An identity is being inivited to become a smith
+        /// An identity is being inivited to become a smith.
         InvitationSent {
             idty_index: T::IdtyIndex,
             invited_by: T::IdtyIndex,
         },
-        /// The invitation has been accepted
+        /// The invitation has been accepted.
         InvitationAccepted { idty_index: T::IdtyIndex },
         /// Certification received
         CertificationReceived {
@@ -142,7 +142,7 @@ pub mod pallet {
         },
         /// A smith gathered enough certifications to become an authority (can call `go_online()`).
         PromotedToSmith { idty_index: T::IdtyIndex },
-        /// A smith has been removed from the smiths set
+        /// A smith has been removed from the smiths set.
         SmithExcluded { idty_index: T::IdtyIndex },
     }
 
diff --git a/resources/metadata.scale b/resources/metadata.scale
index 9c20a389c719ccedf73e8456078a50778a2675e3..820374cd2073ee49d2ba67359255742635e037a9 100644
GIT binary patch
delta 838
zcmZ8fO=uHA6y6uN#wtodOKof8A~uZ}r?!ez=)oo-C2DJJ3x+D_W@p+i+3eWaNo+u<
zh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