From 062867a38dc111fe981e2c65239b557191daa7fa Mon Sep 17 00:00:00 2001 From: Omar Roth Date: Sun, 1 Dec 2019 17:52:39 -0500 Subject: [PATCH] Strip domain from caption URLs --- src/invidious.cr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/invidious.cr b/src/invidious.cr index 6499d569..df6ea3e8 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -3852,7 +3852,7 @@ get "/api/v1/captions/:id" do |env| caption = caption[0] end - url = "#{caption.baseUrl}&tlang=#{tlang}" + url = URI.parse("#{caption.baseUrl}&tlang=#{tlang}").full_path # Auto-generated captions often have cues that aren't aligned properly with the video, # as well as some other markup that makes it cumbersome, so we try to fix that here