mirror of
https://github.com/scrapy/scrapy.git
synced 2025-02-26 23:44:01 +00:00
removed extra return
--HG-- extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%40711
This commit is contained in:
parent
eca60c7c4d
commit
8b28d365b1
@ -23,7 +23,7 @@ def _valid_download_delay(obj):
|
||||
|
||||
class ISpider(Interface, IPlugin) :
|
||||
"""Interface to be implemented by site-specific web spiders"""
|
||||
|
||||
|
||||
domain_name = Attribute(
|
||||
"""The domain name of the site to be scraped.""")
|
||||
|
||||
@ -48,9 +48,9 @@ class ISpider(Interface, IPlugin) :
|
||||
class BaseSpider(object):
|
||||
"""Base class for scrapy spiders. All spiders must inherit from this
|
||||
class.
|
||||
|
||||
|
||||
"""
|
||||
|
||||
|
||||
implements(ISpider)
|
||||
|
||||
start_urls = []
|
||||
@ -86,10 +86,7 @@ class BaseSpider(object):
|
||||
"""
|
||||
if urls is None:
|
||||
urls = self.start_urls
|
||||
requests = [Request(url, callback=self.parse, dont_filter=True) for url in urls]
|
||||
return requests
|
||||
|
||||
return []
|
||||
return [Request(url, callback=self.parse, dont_filter=True) for url in urls]
|
||||
|
||||
def parse(self, response):
|
||||
"""This is the default callback function used to parse the start
|
||||
|
Loading…
x
Reference in New Issue
Block a user