diff options
| author | Omar Roth <omarroth@hotmail.com> | 2018-08-02 17:18:57 -0500 |
|---|---|---|
| committer | Omar Roth <omarroth@hotmail.com> | 2018-08-02 17:18:57 -0500 |
| commit | f249192ebbbbeef5b78a5b5b1c72fcb6a0679477 (patch) | |
| tree | 64a5df4fe540b3daff359ecc56e0dbe927c72eef | |
| parent | 668cd6c3e454fa7c8bed03b0461b52a000f3f0ce (diff) | |
| download | invidious-f249192ebbbbeef5b78a5b5b1c72fcb6a0679477.tar.gz invidious-f249192ebbbbeef5b78a5b5b1c72fcb6a0679477.tar.bz2 invidious-f249192ebbbbeef5b78a5b5b1c72fcb6a0679477.zip | |
Add redirect for '/channels/:ucid/videos'
| -rw-r--r-- | src/invidious.cr | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/invidious.cr b/src/invidious.cr index 9e95121a..2114180c 100644 --- a/src/invidious.cr +++ b/src/invidious.cr @@ -2724,6 +2724,19 @@ get "/channel/:ucid" do |env| templated "channel" end +get "/channel/:ucid/videos" do |env| + ucid = env.params.url["ucid"] + params = env.request.query + + if !params || params.empty? + params = "" + else + params = "?#{params}" + end + + env.redirect "/channel/#{ucid}#{params}" +end + get "/api/manifest/dash/id/:id" do |env| env.response.headers.add("Access-Control-Allow-Origin", "*") env.response.content_type = "application/dash+xml" |
