diff --git a/src/api/mod.rs b/src/api/mod.rs index 4df32aa07..3b1b153e4 100644 --- a/src/api/mod.rs +++ b/src/api/mod.rs @@ -206,14 +206,13 @@ impl TransactionStatus bool { - match self { + matches!( + self, Self::Usurped(_) - | Self::Finalized(_) - | Self::FinalityTimeout(_) - | Self::Invalid - | Self::Dropped => true, - _ => false, - } + | Self::Finalized(_) + | Self::FinalityTimeout(_) + | Self::Invalid | Self::Dropped + ) } } diff --git a/src/api/rpc_api/author.rs b/src/api/rpc_api/author.rs index 182d4d492..a452c8549 100644 --- a/src/api/rpc_api/author.rs +++ b/src/api/rpc_api/author.rs @@ -396,7 +396,7 @@ where let mut subscription: TransactionSubscriptionFor = self.submit_and_watch_opaque_extrinsic(&encoded_extrinsic).await?; - let determinants: Vec<_> = expected_status.into_iter().map(|d| d.as_u8()).collect(); + let determinants: Vec<_> = expected_status.iter().map(|d| d.as_u8()).collect(); while let Some(transaction_status) = subscription.next().await { let transaction_status = transaction_status?;