From afd6bde74dd1d0dcaf4f95d73caa4d4bbbf695c9 Mon Sep 17 00:00:00 2001 From: kolaente Date: Fri, 28 May 2021 08:39:27 +0200 Subject: [PATCH] Make sure the configured frontend url always has a / at the end --- pkg/config/config.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/config/config.go b/pkg/config/config.go index c10cc04c4..64a048e93 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -378,6 +378,10 @@ func InitConfig() { MetricsEnabled.Set(true) } + if ServiceFrontendurl.GetString() != "" && !strings.HasSuffix(ServiceFrontendurl.GetString(), "/") { + ServiceFrontendurl.Set(ServiceFrontendurl.GetString() + "/") + } + log.Printf("Using config file: %s", viper.ConfigFileUsed()) }