mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2022-04-11.git
synced 2024-08-15 00:43:26 +00:00
Try to pull UCID instead of brand name in search results
This commit is contained in:
parent
4480e9c1ba
commit
7fd4c76a59
1 changed files with 3 additions and 1 deletions
|
@ -249,7 +249,9 @@ def extract_items(nodeset, ucid = nil)
|
||||||
)
|
)
|
||||||
when .includes? "yt-lockup-channel"
|
when .includes? "yt-lockup-channel"
|
||||||
author = title.strip
|
author = title.strip
|
||||||
ucid = id.split("/")[-1]
|
|
||||||
|
ucid = node.xpath_node(%q(.//button[contains(@class, "yt-uix-subscription-button")])).try &.["data-channel-external-id"]?
|
||||||
|
ucid ||= id.split("/")[-1]
|
||||||
|
|
||||||
author_thumbnail = node.xpath_node(%q(.//div/span/img)).try &.["data-thumb"]?
|
author_thumbnail = node.xpath_node(%q(.//div/span/img)).try &.["data-thumb"]?
|
||||||
author_thumbnail ||= node.xpath_node(%q(.//div/span/img)).try &.["src"]
|
author_thumbnail ||= node.xpath_node(%q(.//div/span/img)).try &.["src"]
|
||||||
|
|
Loading…
Reference in a new issue