From d177e9706d8580d09c38f346c4d443021c4e90fe Mon Sep 17 00:00:00 2001
From: bgallois <benjamin@gallois.cc>
Date: Fri, 10 May 2024 18:23:42 +0200
Subject: [PATCH] fix clippy

---
 pallets/distance/src/benchmarking.rs                | 3 ++-
 pallets/distance/src/types.rs                       | 2 +-
 pallets/identity/src/traits.rs                      | 1 -
 pallets/oneshot-account/src/benchmarking.rs         | 2 +-
 pallets/provide-randomness/src/benchmarking.rs      | 1 +
 pallets/smith-members/src/impls.rs                  | 1 -
 pallets/universal-dividend/src/benchmarking.rs      | 2 +-
 pallets/universal-dividend/src/compute_claim_uds.rs | 1 -
 primitives/distance/src/lib.rs                      | 2 --
 9 files changed, 6 insertions(+), 9 deletions(-)

diff --git a/pallets/distance/src/benchmarking.rs b/pallets/distance/src/benchmarking.rs
index cf11d85e3..91589bbb3 100644
--- a/pallets/distance/src/benchmarking.rs
+++ b/pallets/distance/src/benchmarking.rs
@@ -15,6 +15,7 @@
 // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
 
 #![cfg(feature = "runtime-benchmarks")]
+#![allow(clippy::multiple_bound_locations)]
 
 use super::*;
 
@@ -26,7 +27,7 @@ use frame_support::traits::{Currency, OnFinalize};
 use frame_system::pallet_prelude::BlockNumberFor;
 use frame_system::RawOrigin;
 use pallet_balances::Pallet as Balances;
-use sp_runtime::traits::{Bounded, One};
+use sp_runtime::traits::Bounded;
 use sp_runtime::Perbill;
 
 use crate::Pallet;
diff --git a/pallets/distance/src/types.rs b/pallets/distance/src/types.rs
index 95ab967e2..cb9f32924 100644
--- a/pallets/distance/src/types.rs
+++ b/pallets/distance/src/types.rs
@@ -18,7 +18,7 @@ pub use crate::{median::*, MAX_EVALUATIONS_PER_SESSION, MAX_EVALUATORS_PER_SESSI
 pub use sp_distance::ComputationResult;
 
 use codec::{Decode, Encode};
-use frame_support::{pallet_prelude::*, BoundedBTreeSet};
+use frame_support::pallet_prelude::*;
 use sp_runtime::Perbill;
 
 /// Status of the distance evaluation of an identity
diff --git a/pallets/identity/src/traits.rs b/pallets/identity/src/traits.rs
index ed8a2e2e4..8031d50c9 100644
--- a/pallets/identity/src/traits.rs
+++ b/pallets/identity/src/traits.rs
@@ -16,7 +16,6 @@
 
 use crate::*;
 use frame_support::pallet_prelude::*;
-use frame_support::weights::Weight;
 
 /// A trait defining operations for checking if identity-related calls are allowed.
 pub trait CheckIdtyCallAllowed<T: Config> {
diff --git a/pallets/oneshot-account/src/benchmarking.rs b/pallets/oneshot-account/src/benchmarking.rs
index cf79d0494..fb389d414 100644
--- a/pallets/oneshot-account/src/benchmarking.rs
+++ b/pallets/oneshot-account/src/benchmarking.rs
@@ -15,13 +15,13 @@
 // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
 
 #![cfg(feature = "runtime-benchmarks")]
+#![allow(clippy::multiple_bound_locations)]
 
 use super::*;
 
 use frame_benchmarking::v2::*;
 use frame_benchmarking::{account, whitelisted_caller};
 use frame_support::pallet_prelude::IsType;
-use frame_support::traits::Get;
 use frame_system::RawOrigin;
 use pallet_balances::Pallet as Balances;
 
diff --git a/pallets/provide-randomness/src/benchmarking.rs b/pallets/provide-randomness/src/benchmarking.rs
index 5f0ed8eed..b5cd3f11b 100644
--- a/pallets/provide-randomness/src/benchmarking.rs
+++ b/pallets/provide-randomness/src/benchmarking.rs
@@ -15,6 +15,7 @@
 // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
 
 #![cfg(feature = "runtime-benchmarks")]
+#![allow(clippy::multiple_bound_locations)]
 
 use super::*;
 
diff --git a/pallets/smith-members/src/impls.rs b/pallets/smith-members/src/impls.rs
index 95a1e49df..c4662164e 100644
--- a/pallets/smith-members/src/impls.rs
+++ b/pallets/smith-members/src/impls.rs
@@ -19,7 +19,6 @@ impl<T: Config> pallet_authority_members::OnIncomingMember<T::MemberId> for Pall
     }
 }
 
-///
 impl<T: Config> pallet_authority_members::OnNewSession for Pallet<T> {
     fn on_new_session(index: SessionIndex) {
         CurrentSession::<T>::put(index);
diff --git a/pallets/universal-dividend/src/benchmarking.rs b/pallets/universal-dividend/src/benchmarking.rs
index 8614441b3..6c1278971 100644
--- a/pallets/universal-dividend/src/benchmarking.rs
+++ b/pallets/universal-dividend/src/benchmarking.rs
@@ -15,6 +15,7 @@
 // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
 
 #![cfg(feature = "runtime-benchmarks")]
+#![allow(clippy::multiple_bound_locations)]
 
 use super::*;
 
@@ -22,7 +23,6 @@ use core::num::NonZeroU16;
 use frame_benchmarking::v2::*;
 use frame_benchmarking::{account, whitelisted_caller};
 use frame_support::pallet_prelude::IsType;
-use frame_support::traits::Get;
 use frame_support::traits::StoredMap;
 use frame_system::RawOrigin;
 use pallet_balances::Pallet as Balances;
diff --git a/pallets/universal-dividend/src/compute_claim_uds.rs b/pallets/universal-dividend/src/compute_claim_uds.rs
index e932e8482..7d58edcea 100644
--- a/pallets/universal-dividend/src/compute_claim_uds.rs
+++ b/pallets/universal-dividend/src/compute_claim_uds.rs
@@ -15,7 +15,6 @@
 // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>.
 
 use super::UdIndex;
-use core::iter::DoubleEndedIterator;
 use sp_arithmetic::traits::{AtLeast32BitUnsigned, Zero};
 
 pub(super) fn compute_claim_uds<Balance: AtLeast32BitUnsigned>(
diff --git a/primitives/distance/src/lib.rs b/primitives/distance/src/lib.rs
index bf878cc9b..5b574aa16 100644
--- a/primitives/distance/src/lib.rs
+++ b/primitives/distance/src/lib.rs
@@ -22,8 +22,6 @@
 use codec::{Decode, Encode};
 use frame_support::pallet_prelude::RuntimeDebug;
 use scale_info::TypeInfo;
-//#[cfg(feature = "std")]
-//use serde::{Deserialize, Serialize};
 use sp_inherents::{InherentData, InherentIdentifier, IsFatalError};
 use sp_runtime::Perbill;
 use sp_std::vec::Vec;
-- 
GitLab