mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 09:51:02 +00:00
Clippyfy (#6341)
* Add clippy config and remove .cargo from gitignore * first fixes * Clippyfied * Add clippy CI job * comment out rusty-cachier * minor * fix ci * remove DAG from check-dependent-project * add DAG to clippy Co-authored-by: alvicsam <alvicsam@gmail.com>
This commit is contained in:
@@ -102,7 +102,7 @@ impl<H, N> CandidatePendingAvailability<H, N> {
|
||||
|
||||
/// Get the core index.
|
||||
pub(crate) fn core_occupied(&self) -> CoreIndex {
|
||||
self.core.clone()
|
||||
self.core
|
||||
}
|
||||
|
||||
/// Get the candidate hash.
|
||||
@@ -383,7 +383,7 @@ impl<T: Config> Pallet<T> {
|
||||
let mut freed_cores = Vec::with_capacity(expected_bits);
|
||||
for (para_id, pending_availability) in assigned_paras_record
|
||||
.into_iter()
|
||||
.filter_map(|x| x)
|
||||
.flatten()
|
||||
.filter_map(|(id, p)| p.map(|p| (id, p)))
|
||||
{
|
||||
if pending_availability.availability_votes.count_ones() >= threshold {
|
||||
@@ -644,8 +644,7 @@ impl<T: Config> Pallet<T> {
|
||||
};
|
||||
|
||||
// one more sweep for actually writing to storage.
|
||||
let core_indices =
|
||||
core_indices_and_backers.iter().map(|&(ref c, _, _)| c.clone()).collect();
|
||||
let core_indices = core_indices_and_backers.iter().map(|&(ref c, _, _)| *c).collect();
|
||||
for (candidate, (core, backers, group)) in
|
||||
candidates.into_iter().zip(core_indices_and_backers)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user