Skip to content

Commit

Permalink
Check to make sure its not nil first
Browse files Browse the repository at this point in the history
  • Loading branch information
HamptonMakes committed Jun 7, 2011
1 parent 3bab70b commit c6cc125
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/parsers/xhtml.rb
Expand Up @@ -41,7 +41,7 @@ def self.parse(article, options = {})

# Fix extensions
page.css("img[@src]").each do |node|
if node["src"][0..2] == "/w/"
if node["src"] && (node["src"][0..2] == "/w/")
node["src"] = "http://" + article.server.host + node["src"]
end
end
Expand Down

0 comments on commit c6cc125

Please sign in to comment.