diff --git a/app/models/topic_embed.rb b/app/models/topic_embed.rb index c9dcc09bf..294f86ff2 100644 --- a/app/models/topic_embed.rb +++ b/app/models/topic_embed.rb @@ -80,7 +80,7 @@ class TopicEmbed < ActiveRecord::Base doc.search(tags.keys.join(',')).each do |node| url_param = tags[node.name] src = node[url_param] - unless (src.empty?) + unless (src.nil? || src.empty?) begin uri = URI.parse(src) unless uri.host