diff options
| author | Omar Roth <omarroth@hotmail.com> | 2018-03-03 15:27:14 -0600 |
|---|---|---|
| committer | Omar Roth <omarroth@hotmail.com> | 2018-03-03 15:27:14 -0600 |
| commit | b8fe82a7f7d05f4a2af0d7445e2633dea5169395 (patch) | |
| tree | 64bc45935f7a24a87d4aaed26ceeababd00e293c /src | |
| parent | 323d27a5f6d4d997cd7ec44b27fad3c37325f9a4 (diff) | |
| download | invidious-b8fe82a7f7d05f4a2af0d7445e2633dea5169395.tar.gz invidious-b8fe82a7f7d05f4a2af0d7445e2633dea5169395.tar.bz2 invidious-b8fe82a7f7d05f4a2af0d7445e2633dea5169395.zip | |
Substitute youtube links in description for local links
Diffstat (limited to 'src')
| -rw-r--r-- | src/helpers.cr | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/helpers.cr b/src/helpers.cr index eeda239a..45204132 100644 --- a/src/helpers.cr +++ b/src/helpers.cr @@ -133,6 +133,7 @@ def fetch_video(id, client) description = html.xpath_node(%q(//p[@id="eow-description"])) description = description ? description.to_xml : "" + description = description.gsub(/(https:\/\/)|(http:\/\/)?(www\.)?(youtube\.com)/, "") wilson_score = ci_lower_bound(likes, likes + dislikes) |
