From de3dcc6f3ea4efbb4f1ed50df2a07a6dbac92ba2 Mon Sep 17 00:00:00 2001 From: Emilien Devos Date: Fri, 15 Oct 2021 23:47:37 +0200 Subject: [PATCH] update PR 2444 --- patches/4-2444.patch | 85 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 82 insertions(+), 3 deletions(-) diff --git a/patches/4-2444.patch b/patches/4-2444.patch index 08b80de..bdac8d0 100644 --- a/patches/4-2444.patch +++ b/patches/4-2444.patch @@ -1,7 +1,7 @@ From 97dc90ae792c3ad876dd5d60c79fb33c23706096 Mon Sep 17 00:00:00 2001 From: syeopite Date: Sat, 2 Oct 2021 11:51:15 -0700 -Subject: [PATCH 1/3] Only use /redirect when automatically redirecting +Subject: [PATCH 1/4] Only use /redirect when automatically redirecting --- src/invidious/routes/misc.cr | 2 +- @@ -214,7 +214,7 @@ index 68e7eb801..845b01177 100644 From 67cd9c0dd96b35d89cd73a6b93c510cc341ccbb5 Mon Sep 17 00:00:00 2001 From: syeopite Date: Sat, 2 Oct 2021 12:25:22 -0700 -Subject: [PATCH 2/3] Remove unneeded redirect.invidious.io code in /redirect +Subject: [PATCH 2/4] Remove unneeded redirect.invidious.io code in /redirect --- src/invidious/routes/misc.cr | 5 ----- @@ -240,7 +240,7 @@ index 94d542836..3ea4c2727 100644 From 2c4a30de554f6405937ef8fee993aa79140f293c Mon Sep 17 00:00:00 2001 From: syeopite Date: Fri, 15 Oct 2021 07:45:36 -0700 -Subject: [PATCH 3/3] Rebase error +Subject: [PATCH 3/4] Rebase error --- src/invidious/views/components/video-context-buttons.ecr | 2 +- @@ -259,3 +259,82 @@ index 062c3de00..daa107f0e 100644 <% else %> + +From 31fd593e93c6e10957001377c8b04add9436e25a Mon Sep 17 00:00:00 2001 +From: syeopite +Date: Fri, 15 Oct 2021 14:40:59 -0700 +Subject: [PATCH 4/4] Use env.request.resource for instance switch link + +--- + src/invidious/views/channel.ecr | 2 +- + src/invidious/views/community.ecr | 2 +- + src/invidious/views/playlist.ecr | 2 +- + src/invidious/views/playlists.ecr | 2 +- + src/invidious/views/watch.ecr | 2 +- + 5 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/src/invidious/views/channel.ecr b/src/invidious/views/channel.ecr +index 66f1ae10e..40b553a9c 100644 +--- a/src/invidious/views/channel.ecr ++++ b/src/invidious/views/channel.ecr +@@ -48,7 +48,7 @@ + <% if env.get("preferences").as(Preferences).automatic_instance_redirect%> + "><%= translate(locale, "Switch Invidious Instance") %> + <% else %> +- "><%= translate(locale, "Switch Invidious Instance") %> ++ <%= translate(locale, "Switch Invidious Instance") %> + <% end %> + + <% if !channel.auto_generated %> +diff --git a/src/invidious/views/community.ecr b/src/invidious/views/community.ecr +index 17bc4f89b..f0add06bf 100644 +--- a/src/invidious/views/community.ecr ++++ b/src/invidious/views/community.ecr +@@ -47,7 +47,7 @@ + <% if env.get("preferences").as(Preferences).automatic_instance_redirect%> + "><%= translate(locale, "Switch Invidious Instance") %> + <% else %> +- "><%= translate(locale, "Switch Invidious Instance") %> ++ <%= translate(locale, "Switch Invidious Instance") %> + <% end %> + + <% if !channel.auto_generated %> +diff --git a/src/invidious/views/playlist.ecr b/src/invidious/views/playlist.ecr +index 4c23ad986..d0518de77 100644 +--- a/src/invidious/views/playlist.ecr ++++ b/src/invidious/views/playlist.ecr +@@ -47,7 +47,7 @@ + <%= translate(locale, "Switch Invidious Instance") %> + + <% else %> +- "> ++ + <%= translate(locale, "Switch Invidious Instance") %> + + <% end %> +diff --git a/src/invidious/views/playlists.ecr b/src/invidious/views/playlists.ecr +index 74890f5a1..12dba088f 100644 +--- a/src/invidious/views/playlists.ecr ++++ b/src/invidious/views/playlists.ecr +@@ -50,7 +50,7 @@ + <% if env.get("preferences").as(Preferences).automatic_instance_redirect%> + "><%= translate(locale, "Switch Invidious Instance") %> + <% else %> +- "><%= translate(locale, "Switch Invidious Instance") %> ++ <%= translate(locale, "Switch Invidious Instance") %> + <% end %> + + +diff --git a/src/invidious/views/watch.ecr b/src/invidious/views/watch.ecr +index 845b01177..6018e5c2d 100644 +--- a/src/invidious/views/watch.ecr ++++ b/src/invidious/views/watch.ecr +@@ -119,7 +119,7 @@ we're going to need to do it here in order to allow for translations. + <% if env.get("preferences").as(Preferences).automatic_instance_redirect%> + "><%= translate(locale, "Switch Invidious Instance") %> + <% else %> +- "><%= translate(locale, "Switch Invidious Instance") %> ++ <%= translate(locale, "Switch Invidious Instance") %> + <% end %> +

+