Bumping clippy & fixing warnings (#1823)

* Bumping clippy

* Fixing clippy warnings

* Cargo.lock (latest nightly?)
This commit is contained in:
Tomasz Drwięga
2016-08-03 19:01:48 +02:00
committed by Gav Wood
parent 531bc79edc
commit deceb5fd56
22 changed files with 194 additions and 48 deletions

View File

@@ -20,7 +20,7 @@ ethcore-util = { path = "../util" }
ethcore-rpc = { path = "../rpc" }
parity-dapps-signer = { git = "https://github.com/ethcore/parity-ui.git", version = "0.6", optional = true}
clippy = { version = "0.0.79", optional = true}
clippy = { version = "0.0.80", optional = true}
[features]
dev = ["clippy"]

View File

@@ -103,6 +103,7 @@ pub struct Session {
}
impl ws::Handler for Session {
#[cfg_attr(feature="dev", allow(collapsible_if))]
fn on_request(&mut self, req: &ws::Request) -> ws::Result<(ws::Response)> {
let origin = req.header("origin").or_else(|| req.header("Origin")).map(|x| &x[..]);
let host = req.header("host").or_else(|| req.header("Host")).map(|x| &x[..]);