mirror of
https://github.com/iv-org/invidious.git
synced 2024-11-10 09:07:48 +01:00
Fix default value for empty description
This commit is contained in:
parent
e61c8046f4
commit
2d59fdd178
1 changed files with 1 additions and 1 deletions
|
@ -1228,7 +1228,7 @@ def fetch_video(id, region)
|
||||||
avg_rating = avg_rating.nan? ? 0.0 : avg_rating
|
avg_rating = avg_rating.nan? ? 0.0 : avg_rating
|
||||||
info["avg_rating"] = "#{avg_rating}"
|
info["avg_rating"] = "#{avg_rating}"
|
||||||
|
|
||||||
description_html = html.xpath_node(%q(//p[@id="eow-description"])).try &.to_xml(options: XML::SaveOptions::NO_DECL) || ""
|
description_html = html.xpath_node(%q(//p[@id="eow-description"])).try &.to_xml(options: XML::SaveOptions::NO_DECL) || "<p></p>"
|
||||||
wilson_score = ci_lower_bound(likes, likes + dislikes)
|
wilson_score = ci_lower_bound(likes, likes + dislikes)
|
||||||
|
|
||||||
published = html.xpath_node(%q(//meta[@itemprop="datePublished"])).try &.["content"]
|
published = html.xpath_node(%q(//meta[@itemprop="datePublished"])).try &.["content"]
|
||||||
|
|
Loading…
Reference in a new issue