diff options
Diffstat (limited to 'src/urllib3/connectionpool.py')
-rw-r--r-- | src/urllib3/connectionpool.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/urllib3/connectionpool.py b/src/urllib3/connectionpool.py index 96339e90..70873927 100644 --- a/src/urllib3/connectionpool.py +++ b/src/urllib3/connectionpool.py @@ -862,7 +862,7 @@ class HTTPConnectionPool(ConnectionPool, RequestMethods): ) # Check if we should retry the HTTP response. - has_retry_after = bool(response.getheader("Retry-After")) + has_retry_after = bool(response.headers.get("Retry-After")) if retries.is_retry(method, response.status, has_retry_after): try: retries = retries.increment(method, url, response=response, _pool=self) |