mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 07:37:57 +00:00
Easy PR: Fix warnings from latest nightly (#14195)
* unneeded mut * remove needless borrows
This commit is contained in:
@@ -1006,9 +1006,7 @@ pub mod pallet {
|
||||
|
||||
// Note: in case there is no current era it is fine to bond one era more.
|
||||
let era = Self::current_era().unwrap_or(0) + T::BondingDuration::get();
|
||||
if let Some(mut chunk) =
|
||||
ledger.unlocking.last_mut().filter(|chunk| chunk.era == era)
|
||||
{
|
||||
if let Some(chunk) = ledger.unlocking.last_mut().filter(|chunk| chunk.era == era) {
|
||||
// To keep the chunk count down, we only keep one chunk per era. Since
|
||||
// `unlocking` is a FiFo queue, if a chunk exists for `era` we know that it will
|
||||
// be the last one.
|
||||
|
||||
Reference in New Issue
Block a user