Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
MVP fix
  • Loading branch information
drahnr committed Oct 2, 2021
commit c5f7303f2a1ee66de196b54d94b94b8ecc87755d
10 changes: 8 additions & 2 deletions runtime/parachains/src/inclusion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -320,9 +320,15 @@ impl<T: Config> Pallet<T> {
for (bit_idx, _) in
signed_bitfield.payload().0.iter().enumerate().filter(|(_, is_av)| **is_av)
{
let (_, pending_availability) = assigned_paras_record[bit_idx]
let pending_availability = if let Some((_, pending_availability)) = assigned_paras_record[bit_idx]
.as_mut()
.expect("validator bitfields checked not to contain bits corresponding to unoccupied cores; qed");
{
pending_availability
} else {
// only happens in case of unoccupied cores, which in turn happens in case
// of disputes.
continue;
};

// defensive check - this is constructed by loading the availability bitfield record,
// which is always `Some` if the core is occupied - that's why we're here.
Expand Down