mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 12:19:24 +00:00
Update Rust nightly
Supersedes #368. Adds exceptions for unwrap_or_default due to preference against Default's ambiguity.
This commit is contained in:
@@ -35,6 +35,7 @@ impl<D: Db, T: TransactionTrait> Mempool<D, T> {
|
||||
let tx_hash = tx.hash();
|
||||
let transaction_key = self.transaction_key(&tx_hash);
|
||||
let current_mempool_key = self.current_mempool_key();
|
||||
#[allow(clippy::unwrap_or_default)]
|
||||
let mut current_mempool = self.db.get(¤t_mempool_key).unwrap_or(vec![]);
|
||||
|
||||
let mut txn = self.db.txn();
|
||||
@@ -225,6 +226,7 @@ impl<D: Db, T: TransactionTrait> Mempool<D, T> {
|
||||
pub(crate) fn remove(&mut self, tx: &[u8; 32]) {
|
||||
let transaction_key = self.transaction_key(tx);
|
||||
let current_mempool_key = self.current_mempool_key();
|
||||
#[allow(clippy::unwrap_or_default)]
|
||||
let current_mempool = self.db.get(¤t_mempool_key).unwrap_or(vec![]);
|
||||
|
||||
let mut i = 0;
|
||||
|
||||
@@ -77,6 +77,7 @@ impl<D: Db, T: Transaction> ProvidedTransactions<D, T> {
|
||||
}
|
||||
|
||||
let current_provided_key = self.current_provided_key();
|
||||
#[allow(clippy::unwrap_or_default)]
|
||||
let mut currently_provided = self.db.get(¤t_provided_key).unwrap_or(vec![]);
|
||||
|
||||
let mut txn = self.db.txn();
|
||||
|
||||
Reference in New Issue
Block a user