From c41beae99a1b522de0d1dd2bda3e38ffd294d2c7 Mon Sep 17 00:00:00 2001 From: Omar Roth Date: Thu, 1 Aug 2019 07:49:33 -0500 Subject: [PATCH] Add fix for channels with empty descriptions --- src/invidious/channels.cr | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/invidious/channels.cr b/src/invidious/channels.cr index 792ed288..5e01cef2 100644 --- a/src/invidious/channels.cr +++ b/src/invidious/channels.cr @@ -958,7 +958,8 @@ def get_about_info(ucid, locale) banner = nil end - description_html = about.xpath_node(%q(//div[contains(@class,"about-description")])).try &.to_s || "" + description_html = about.xpath_node(%q(//div[contains(@class,"about-description")])).try &.to_s || + %(
) paid = about.xpath_node(%q(//meta[@itemprop="paid"])).not_nil!["content"] == "True" is_family_friendly = about.xpath_node(%q(//meta[@itemprop="isFamilyFriendly"])).not_nil!["content"] == "True"