summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/invidious.cr12
-rw-r--r--src/invidious/helpers/helpers.cr2
2 files changed, 13 insertions, 1 deletions
diff --git a/src/invidious.cr b/src/invidious.cr
index 6e97c70e..e57dd5c6 100644
--- a/src/invidious.cr
+++ b/src/invidious.cr
@@ -2689,6 +2689,18 @@ options "/videoplayback/*" do |env|
env.response.headers["Access-Control-Allow-Headers"] = "Content-Type, range"
end
+options "/api/manifest/dash/id/videoplayback" do |env|
+ env.response.headers["Access-Control-Allow-Origin"] = "*"
+ env.response.headers["Access-Control-Allow-Methods"] = "GET"
+ env.response.headers["Access-Control-Allow-Headers"] = "Content-Type, range"
+end
+
+options "/api/manifest/dash/id/videoplayback/*" do |env|
+ env.response.headers["Access-Control-Allow-Origin"] = "*"
+ env.response.headers["Access-Control-Allow-Methods"] = "GET"
+ env.response.headers["Access-Control-Allow-Headers"] = "Content-Type, range"
+end
+
get "/videoplayback/*" do |env|
path = env.request.path
diff --git a/src/invidious/helpers/helpers.cr b/src/invidious/helpers/helpers.cr
index 874927e5..fcc191f6 100644
--- a/src/invidious/helpers/helpers.cr
+++ b/src/invidious/helpers/helpers.cr
@@ -17,7 +17,7 @@ class Config
end
class FilteredCompressHandler < Kemal::Handler
- exclude ["/videoplayback/*", "/api/*"]
+ exclude ["/videoplayback", "/api/*"]
def call(env)
return call_next env if exclude_match? env