metainspector 1.9.4 → 1.9.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/meta_inspector/scraper.rb +2 -1
- data/lib/meta_inspector/version.rb +1 -1
- data/spec/fixtures/twitter_w3clove.response +4232 -0
- data/spec/metainspector_spec.rb +27 -19
- metadata +4 -3
@@ -154,12 +154,13 @@ module MetaInspector
|
|
154
154
|
|
155
155
|
def parsed_images
|
156
156
|
@parsed_images ||= parsed_document.search('//img') \
|
157
|
-
.reject{|i| i.attributes['src'].
|
157
|
+
.reject{|i| (i.attributes['src'].nil? || i.attributes['src'].value.empty?) } \
|
158
158
|
.map{ |i| i.attributes['src'].value }.uniq
|
159
159
|
end
|
160
160
|
|
161
161
|
# Stores the error for later inspection
|
162
162
|
def add_fatal_error(error)
|
163
|
+
warn error
|
163
164
|
@errors << error
|
164
165
|
end
|
165
166
|
|