diff --git a/src/invidious/routes/misc.cr b/src/invidious/routes/misc.cr index 0e6356d0..3ea4c272 100644 --- a/src/invidious/routes/misc.cr +++ b/src/invidious/routes/misc.cr @@ -40,11 +40,6 @@ module Invidious::Routes::Misc def self.cross_instance_redirect(env) referer = get_referer(env) - - if !env.get("preferences").as(Preferences).automatic_instance_redirect - return env.redirect("https://redirect.invidious.io#{referer}") - end - instance_url = fetch_random_instance env.redirect "https://#{instance_url}#{referer}" end diff --git a/src/invidious/views/channel.ecr b/src/invidious/views/channel.ecr index 7f797e37..40b553a9 100644 --- a/src/invidious/views/channel.ecr +++ b/src/invidious/views/channel.ecr @@ -45,7 +45,11 @@
+ <% if env.get("preferences").as(Preferences).automatic_instance_redirect%> "><%= translate(locale, "Switch Invidious Instance") %> + <% else %> + <%= translate(locale, "Switch Invidious Instance") %> + <% end %>