diff --git a/ethcore/src/client/client.rs b/ethcore/src/client/client.rs index bf318aeda..0e0b292f9 100644 --- a/ethcore/src/client/client.rs +++ b/ethcore/src/client/client.rs @@ -891,12 +891,9 @@ impl BlockChainClient for Client { let mut mode = self.mode.lock(); *mode = new_mode.clone().into(); trace!(target: "mode", "Mode now {:?}", &*mode); - match *self.on_mode_change.lock() { - Some(ref mut f) => { - trace!(target: "mode", "Making callback..."); - f(&*mode) - }, - _ => {} + if let Some(ref mut f) = *self.on_mode_change.lock() { + trace!(target: "mode", "Making callback..."); + f(&*mode) } } match new_mode { diff --git a/ethcore/src/miner/miner.rs b/ethcore/src/miner/miner.rs index df55e7367..5530ac462 100644 --- a/ethcore/src/miner/miner.rs +++ b/ethcore/src/miner/miner.rs @@ -38,7 +38,6 @@ use miner::price_info::PriceInfo; use miner::local_transactions::{Status as LocalTransactionStatus}; use header::BlockNumber; - /// Different possible definitions for pending transaction set. #[derive(Debug, PartialEq)] pub enum PendingSet { diff --git a/ethcore/src/miner/transaction_queue.rs b/ethcore/src/miner/transaction_queue.rs index 00fe47243..bfbd3fade 100644 --- a/ethcore/src/miner/transaction_queue.rs +++ b/ethcore/src/miner/transaction_queue.rs @@ -2137,12 +2137,11 @@ mod test { let mut txq = TransactionQueue::with_limits(PrioritizationStrategy::GasPriceOnly, 100, default_gas_val() * U256::from(2), !U256::zero()); let (tx1, tx2) = new_tx_pair_default(U256::from(1), U256::from(1)); let (tx3, tx4) = new_tx_pair_default(U256::from(1), U256::from(2)); - let (tx5, tx6) = new_tx_pair_default(U256::from(1), U256::from(2)); + let (tx5, _) = new_tx_pair_default(U256::from(1), U256::from(2)); txq.add(tx1.clone(), TransactionOrigin::Local, &default_account_details, &gas_estimator).unwrap(); txq.add(tx2.clone(), TransactionOrigin::Local, &default_account_details, &gas_estimator).unwrap(); // Not accepted because of limit txq.add(tx5.clone(), TransactionOrigin::External, &default_account_details, &gas_estimator).unwrap_err(); - txq.add(tx6.clone(), TransactionOrigin::External, &default_account_details, &gas_estimator).unwrap_err(); txq.add(tx3.clone(), TransactionOrigin::Local, &default_account_details, &gas_estimator).unwrap(); txq.add(tx4.clone(), TransactionOrigin::Local, &default_account_details, &gas_estimator).unwrap(); assert_eq!(txq.status().pending, 4); diff --git a/js/src/views/Dapps/builtin.json b/js/src/views/Dapps/builtin.json index 71f3cd6ed..a2959bb18 100644 --- a/js/src/views/Dapps/builtin.json +++ b/js/src/views/Dapps/builtin.json @@ -49,5 +49,4 @@ "version": "1.0.0", "secure": true } - ] diff --git a/rpc/src/v1/types/transaction.rs b/rpc/src/v1/types/transaction.rs index 7379a3b19..45f1cdd5e 100644 --- a/rpc/src/v1/types/transaction.rs +++ b/rpc/src/v1/types/transaction.rs @@ -132,7 +132,6 @@ impl Serialize for LocalTransactionStatus { } } - impl From for Transaction { fn from(t: LocalizedTransaction) -> Transaction { let signature = t.signature(); diff --git a/sync/build.rs b/sync/build.rs index db881e328..c465d5e34 100644 --- a/sync/build.rs +++ b/sync/build.rs @@ -18,5 +18,4 @@ extern crate ethcore_ipc_codegen; fn main() { ethcore_ipc_codegen::derive_ipc_cond("src/api.rs", cfg!(feature="ipc")).unwrap(); - ethcore_ipc_codegen::derive_ipc_cond("src/transactions_stats.rs", cfg!(feature="ipc")).unwrap(); }