Skip to content

Commit

Permalink
Update auto_crawler.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoongi Kim committed Nov 21, 2018
1 parent 726154e commit 542d6e3
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions auto_crawler.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,10 @@ def download_from_site(self, keyword, site, collect_links_func):
print('Exception {} - {}'.format(keyword, e))

def download(self, args):
func = None
if args[1] == 'google':
func = google.collect_links
self.download_from_site(keyword=args[0], site=args[1], collect_links_func=google.collect_links)
elif args[1] == 'naver':
func = naver.collect_links

self.download_from_site(keyword=args[0], site=args[1], collect_links_func=func)
self.download_from_site(keyword=args[0], site=args[1], collect_links_func=naver.collect_links)

def do_crawling(self):
keywords = self.get_keywords()
Expand Down

0 comments on commit 542d6e3

Please sign in to comment.