Fix warnings: other
This commit is contained in:
parent
412d0307cb
commit
c270599a23
@ -14,6 +14,8 @@
|
|||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with Parity Ethereum. If not, see <http://www.gnu.org/licenses/>.
|
// along with Parity Ethereum. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
#![allow(deprecated)]
|
||||||
|
|
||||||
use parity_crypto::error::SymmError;
|
use parity_crypto::error::SymmError;
|
||||||
use secp256k1;
|
use secp256k1;
|
||||||
use std::io;
|
use std::io;
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
use ethereum_types::H256;
|
use ethereum_types::H256;
|
||||||
use jsonrpc_tcp_server::PushMessageError;
|
use jsonrpc_tcp_server::PushMessageError;
|
||||||
use std::{self, error::Error as StdError};
|
use std;
|
||||||
|
|
||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
pub enum Error {
|
pub enum Error {
|
||||||
@ -29,7 +29,7 @@ pub enum Error {
|
|||||||
|
|
||||||
impl From<std::io::Error> for Error {
|
impl From<std::io::Error> for Error {
|
||||||
fn from(err: std::io::Error) -> Self {
|
fn from(err: std::io::Error) -> Self {
|
||||||
Error::Io(err.description().to_owned())
|
Error::Io(err.to_string())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -214,7 +214,7 @@ fn guess_mime_type(url: &str) -> Option<Mime> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
url.and_then(|url| url.split('.').last())
|
url.and_then(|url| url.split('.').last())
|
||||||
.and_then(|extension| mime_guess::get_mime_type_opt(extension))
|
.and_then(|extension| mime_guess::from_ext(extension).first())
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
|
Loading…
Reference in New Issue
Block a user