Invidious is an alternative front-end to YouTube
Add 'external_port'
Omar Rothbc1e62ce5162
diff --git a/src/invidious/helpers/helpers.cr b/src/invidious/helpers/helpers.crindex 3cc4d9cf..075bf84e 100644--- a/src/invidious/helpers/helpers.cr+++ b/src/invidious/helpers/helpers.cr@@ -24,6 +24,7 @@ user: String,registration_enabled: {type: Bool, default: true},statistics_enabled: {type: Bool, default: false},admins: {type: Array(String), default: [] of String},+ external_port: {type: Int32 | Nil, default: nil},})enddiff --git a/src/invidious/helpers/utils.cr b/src/invidious/helpers/utils.crindex c200801f..3123b1d2 100644--- a/src/invidious/helpers/utils.cr+++ b/src/invidious/helpers/utils.cr@@ -195,6 +195,7 @@ enddef make_host_url(config, kemal_config)ssl = config.https_only || kemal_config.ssl+ port = config.external_port || kemal_config.portif sslscheme = "https://"@@ -202,7 +203,8 @@ def make_host_url(config, kemal_config)scheme = "http://"end- if kemal_config.port != 80 && kemal_config.port != 443+ # Add if non-standard port+ if port != 80 && port != 443port = ":#{kemal_config.port}"elseport = ""