mirror of https://github.com/scrapy/scrapy.git
removed deprecation warning for spider.download_timeout attribute
This commit is contained in:
parent
c38c49d56a
commit
c085f81641
|
|
@ -4,7 +4,6 @@ Download timeout middleware
|
|||
See documentation in docs/topics/downloader-middleware.rst
|
||||
"""
|
||||
from scrapy.utils.python import WeakKeyCache
|
||||
from scrapy.utils import deprecate
|
||||
|
||||
|
||||
class DownloadTimeoutMiddleware(object):
|
||||
|
|
@ -14,7 +13,6 @@ class DownloadTimeoutMiddleware(object):
|
|||
|
||||
def _download_timeout(self, spider):
|
||||
if hasattr(spider, 'download_timeout'):
|
||||
deprecate.attribute(spider, 'download_timeout', 'DOWNLOAD_TIMEOUT')
|
||||
return spider.download_timeout
|
||||
return spider.settings.getint('DOWNLOAD_TIMEOUT')
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue