Class: TomosiaWallhereCrawl::Cli

Inherits:
Thor
  • Object
show all
Defined in:
lib/tomosia_wallhere_crawl/cli.rb

Instance Method Summary collapse

Instance Method Details

#crawl(keyword) ⇒ Object



9
10
11
12
13
14
15
# File 'lib/tomosia_wallhere_crawl/cli.rb', line 9

def crawl(keyword)
  if options[:max] == nil
    TomosiaWallhereCrawl::CrawlImage.new.crawldata(keyword, options[:destination], options[:max])
  else
    TomosiaWallhereCrawl::CrawlImage.new.crawldata(keyword, options[:destination], options[:max].to_i)
  end
end