summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/invidious.cr2
-rw-r--r--src/invidious/helpers/handlers.cr5
2 files changed, 6 insertions, 1 deletions
diff --git a/src/invidious.cr b/src/invidious.cr
index 1399c124..1603f4e6 100644
--- a/src/invidious.cr
+++ b/src/invidious.cr
@@ -5168,7 +5168,7 @@ get "/sb/:id/:storyboard/:index" do |env|
env.response.headers[key] = value
end
- if response.status_code == 304
+ if response.status_code >= 400
break
end
diff --git a/src/invidious/helpers/handlers.cr b/src/invidious/helpers/handlers.cr
index 560ed670..98087ec7 100644
--- a/src/invidious/helpers/handlers.cr
+++ b/src/invidious/helpers/handlers.cr
@@ -33,6 +33,11 @@ class Kemal::RouteHandler
raise Kemal::Exceptions::CustomException.new(context)
end
+ if context.request.method == "HEAD" &&
+ context.request.path.ends_with? ".jpg"
+ context.response.headers["Content-Type"] = "image/jpeg"
+ end
+
context.response.print(content)
context
end
='2024-04-25 18:35:08 +0200'>2024-04-25Update Interlingua translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Software In Interlingua <softinterlingua@gmail.com> 2024-04-25Update Arabic translationHosted Weblate Update Arabic translation Update Arabic translation Update Arabic translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Rex_sa <rex.sa@pm.me> Co-authored-by: Samantaz Fox <translator-weblate@samantaz.fr> 2024-04-25Update Italian translationHosted Weblate Update Italian translation Co-authored-by: Federico <fv4@users.noreply.hosted.weblate.org> Co-authored-by: Hosted Weblate <hosted@weblate.org> 2024-04-25Update Polish translationHosted Weblate Update Polish translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Matthaiks <kitynska@gmail.com> 2024-04-25Update Hindi translationHosted Weblate Update Hindi translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Scrambled777 <weblate.scrambled777@simplelogin.com> 2024-04-25Update Croatian translationHosted Weblate Update Croatian translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Milo Ivir <mail@milotype.de> 2024-04-25Update Vietnamese translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Knight Hat <knightchanelgaming@gmail.com> 2024-04-25Update Portuguese translationHosted Weblate Update Portuguese translation Update Portuguese translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Samantaz Fox <translator-weblate@samantaz.fr> Co-authored-by: Sergio Marques <so.boston.android@gmail.com> 2024-04-25Update Czech translationHosted Weblate Update Czech translation Co-authored-by: Fjuro <fjuro@alius.cz> Co-authored-by: Hosted Weblate <hosted@weblate.org> 2024-04-25Update Japanese translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: maboroshin <maboroshin@users.noreply.hosted.weblate.org> 2024-04-25Update Ukrainian translationHosted Weblate Update Ukrainian translation Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Ihor Hordiichuk <igor_ck@outlook.com> Co-authored-by: Samantaz Fox <translator-weblate@samantaz.fr> 2024-04-25Update Bengali translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Tauhid Alam Rifty <tauhidalamrifty@gmail.com> 2024-04-25Update Romanian translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Wiktor Muzynski <wiktormuzynski@gmail.com> 2024-04-25Update Basque translationHosted Weblate Co-authored-by: Samantaz Fox <translator-weblate@samantaz.fr> 2024-04-25Update Danish translationHosted Weblate Co-authored-by: Samantaz Fox <translator-weblate@samantaz.fr> 2024-04-25Update German translationHosted Weblate Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Lenny Angst <lenny@familie-angst.ch> 2024-04-25Update Portuguese (Brazil) translationHosted Weblate Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Update Portuguese (Brazil) translation Co-authored-by: André Marcelo Alvarenga <andrealvarenga@gmx.net> Co-authored-by: Hosted Weblate <hosted@weblate.org> Co-authored-by: Jose Delvani <delvani.eletricista@gmail.com> Co-authored-by: joaooliva <joaooliva@protonmail.com>