Remove proxy method on request (#220)
This commit is contained in:
committed by
GitHub
parent
d6f31ebb52
commit
920eccf37a
@@ -9,7 +9,6 @@ use crate::body::BodySize;
|
||||
use crate::body::{Payload, SizedReader};
|
||||
use crate::error::Error;
|
||||
use crate::header::{self, Header};
|
||||
use crate::proxy::Proxy;
|
||||
use crate::unit::{self, Unit};
|
||||
use crate::Response;
|
||||
|
||||
@@ -419,14 +418,6 @@ impl Request {
|
||||
Url::parse(&self.url).map_err(|e| Error::BadUrl(format!("{}", e)))
|
||||
}
|
||||
|
||||
pub(crate) fn proxy(&self) -> Option<Proxy> {
|
||||
if let Some(proxy) = &self.agent.config.proxy {
|
||||
Some(proxy.clone())
|
||||
} else {
|
||||
None
|
||||
}
|
||||
}
|
||||
|
||||
// Returns true if this request, with the provided body, is retryable.
|
||||
pub(crate) fn is_retryable(&self, body: &SizedReader) -> bool {
|
||||
// Per https://tools.ietf.org/html/rfc7231#section-8.1.3
|
||||
|
||||
Reference in New Issue
Block a user