Fix some warnings in future Rust nightlies

This commit is contained in:
Simon Sapin 2020-01-02 16:41:47 +01:00
parent 7281336116
commit fdcc7653f2
8 changed files with 20 additions and 45 deletions

View file

@ -31,7 +31,6 @@ use ipc_channel::Error as IpcError;
use mime::Mime;
use msg::constellation_msg::HistoryStateId;
use servo_url::ServoUrl;
use std::error::Error;
use time::precise_time_ns;
use webrender_api::ImageKey;
@ -699,11 +698,11 @@ pub enum NetworkError {
impl NetworkError {
pub fn from_hyper_error(error: &HyperError) -> Self {
NetworkError::Internal(error.description().to_owned())
NetworkError::Internal(error.to_string())
}
pub fn from_http_error(error: &HttpError) -> Self {
NetworkError::Internal(error.description().to_owned())
NetworkError::Internal(error.to_string())
}
}