lib/youtube_search.rb in youtube_search-0.1.5 vs lib/youtube_search.rb in youtube_search-0.1.6
- old
+ new
@@ -26,9 +26,12 @@
end
duration = element.elements['*/yt:duration']
entry['duration'] = duration.attributes['seconds'] if duration
+ no_embed = element.elements['yt:noembed'] || element.elements['yt:private']
+ entry['embeddable'] = !(no_embed)
+
entry['raw'] = element
entry
end
end