mirror of
				https://gitea.invidious.io/iv-org/invidious
				synced 2025-06-05 23:29:12 +02:00 
			
		
		
		
	Add alt links for all youtube endpoints
This commit is contained in:
		@@ -484,7 +484,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" || url.path == "/redirect"
 | 
			
		||||
    if ["www.youtube.com", "m.youtube.com"].includes?(url.host)
 | 
			
		||||
      alt_link = <<-END_HTML
 | 
			
		||||
      <a href="#{url.full_path}">
 | 
			
		||||
        <i class="fa fa-link" aria-hidden="true"></i>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user