summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorepicsam123 <92618898+epicsam123@users.noreply.github.com>2025-01-24 21:54:10 -0500
committerGitHub <noreply@github.com>2025-01-24 21:54:10 -0500
commitafb0aad7d36bf907b46df87432c65a9b45eb678d (patch)
tree60e4024c8bf3c14946b416b4cc9777c6e38762af /src
parent6816ded0fa29dd5d45e0858b5dd8fbe8d0f3f35a (diff)
downloadinvidious-afb0aad7d36bf907b46df87432c65a9b45eb678d.tar.gz
invidious-afb0aad7d36bf907b46df87432c65a9b45eb678d.tar.bz2
invidious-afb0aad7d36bf907b46df87432c65a9b45eb678d.zip
moved comments
Diffstat (limited to 'src')
-rw-r--r--src/invidious/routes/misc.cr4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/invidious/routes/misc.cr b/src/invidious/routes/misc.cr
index 27a28994..96d6e61f 100644
--- a/src/invidious/routes/misc.cr
+++ b/src/invidious/routes/misc.cr
@@ -46,13 +46,13 @@ module Invidious::Routes::Misc
if instance_list.empty?
instance_url = redirect_url
else
- # Sample returns an array
- # Instances are packaged as {region, domain} in the instance list
# Filter out the current instance
other_available_instances = instance_list.reject! { |region, domain| domain == CONFIG.domain }
# If there are any other instances, select a random one
if other_available_instances.any?
+ # Sample returns an array
+ # Instances are packaged as {region, domain} in the instance list
instance_url = other_available_instances.sample(1)[0][1]
else
# If the current instance is the only one, use the redirect URL as fallback