Skip to content

Commit

Permalink
fix: trim html template class
Browse files Browse the repository at this point in the history
  • Loading branch information
kjellberg committed Jan 15, 2024
1 parent af3af30 commit 9f67551
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
google_parser (0.1.0)
google_parser (0.1.1)
nokogiri (~> 1.15.3)

GEM
Expand Down
2 changes: 1 addition & 1 deletion lib/google_parser.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def initialize(raw_html)
@raw_html = raw_html
@doc = Nokogiri::HTML(raw_html)
@organic_results = []
@jsmodel = @doc.css("body").attr("jsmodel").value
@jsmodel = @doc.css("body").attr("jsmodel").value&.strip!

parse_organic_results
rescue StandardError => e
Expand Down
2 changes: 1 addition & 1 deletion lib/google_parser/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module GoogleParser
VERSION = "0.1.0"
VERSION = "0.1.1"
end

0 comments on commit 9f67551

Please sign in to comment.