diff options
| author | Omar Roth <omarroth@hotmail.com> | 2018-04-07 10:13:52 -0500 |
|---|---|---|
| committer | Omar Roth <omarroth@hotmail.com> | 2018-04-07 10:13:52 -0500 |
| commit | 1a458ee94c77479660853909ebc783af4d992756 (patch) | |
| tree | cafd664c2342de6339461b7778f4bac4cf9727af /src | |
| parent | 69dd52bac3b480ae932452c2bea6bab3de1d9892 (diff) | |
| download | invidious-1a458ee94c77479660853909ebc783af4d992756.tar.gz invidious-1a458ee94c77479660853909ebc783af4d992756.tar.bz2 invidious-1a458ee94c77479660853909ebc783af4d992756.zip | |
Substitute redirect links in video description
Diffstat (limited to 'src')
| -rw-r--r-- | src/helpers.cr | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/helpers.cr b/src/helpers.cr index 3208ced8..4fe8ae4f 100644 --- a/src/helpers.cr +++ b/src/helpers.cr @@ -448,7 +448,7 @@ def add_alt_links(html) anchor = anchor.xpath_node("//a").not_nil! url = URI.parse(HTML.unescape(anchor["href"])) - if ["www.youtube.com", "m.youtube.com"].includes?(url.host) && url.path == "/watch" + if ["www.youtube.com", "m.youtube.com"].includes?(url.host) && url.path == "/watch" || url.path == "/redirect" alt_link = <<-END_HTML <a href="#{url.full_path}"> <i class="fa fa-link" aria-hidden="true"></i> |
