From c26d9545a50dda933ed9e84d8588298adf3468ee Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Wed, 7 Mar 2018 12:09:53 -0800 Subject: [PATCH] map connector timeout error --- src/client/connector.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/client/connector.rs b/src/client/connector.rs index 66c21e890..f5ac70aee 100644 --- a/src/client/connector.rs +++ b/src/client/connector.rs @@ -92,7 +92,10 @@ pub enum ClientConnectorError { impl From for ClientConnectorError { fn from(err: ConnectorError) -> ClientConnectorError { - ClientConnectorError::Connector(err) + match err { + ConnectorError::Timeout => ClientConnectorError::Timeout, + _ => ClientConnectorError::Connector(err) + } } }