gsearch-parser 0.3.6 → 0.3.7

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.6
1
+ 0.3.7
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "gsearch-parser"
8
- s.version = "0.3.6"
8
+ s.version = "0.3.7"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Diego Netto"]
@@ -74,6 +74,7 @@ class GoogleWebSearch
74
74
 
75
75
  # Iterate over each Google result list element
76
76
  @currentPage.css('li.g').each do |result|
77
+ begin
77
78
  # Extract the title
78
79
  title = result.css('h3 a').first.inner_html
79
80
 
@@ -91,6 +92,9 @@ class GoogleWebSearch
91
92
 
92
93
  # Create a new Result object and append to the array
93
94
  currentResults << Result.new(title, content, uri)
95
+ rescue NoMethodError
96
+ next
97
+ end
94
98
  end
95
99
  @results += currentResults
96
100
  return currentResults
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gsearch-parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.6
4
+ version: 0.3.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: