Update channel feed

This commit is contained in:
Omar Roth 2018-08-05 14:26:41 -05:00
parent e47b95ff42
commit d51b23bc16
2 changed files with 35 additions and 21 deletions

View file

@ -33,7 +33,7 @@ def search(query, page = 1, search_params = build_search_params(content_type: "v
end
title = anchor.content.strip
id = anchor["href"].lchop("/watch?v=")
video_id = anchor["href"].lchop("/watch?v=")
anchor = node.xpath_node(%q(.//div[contains(@class, "yt-lockup-byline")]/a)).not_nil!
author = anchor.content
@ -77,7 +77,7 @@ def search(query, page = 1, search_params = build_search_params(content_type: "v
video = SearchVideo.new(
title,
id,
video_id,
author,
ucid,
published,