fix: #10473, trim trailing slashes on config url

This commit is contained in:
Julian Lam
2022-04-08 10:10:58 -04:00
parent 91026e5f14
commit 9f91db16cb

View File

@@ -87,6 +87,7 @@ function loadConfig(configFile) {
} }
if (nconf.get('url')) { if (nconf.get('url')) {
nconf.set('url', nconf.get('url').replace(/\/$/, ''));
nconf.set('url_parsed', url.parse(nconf.get('url'))); nconf.set('url_parsed', url.parse(nconf.get('url')));
// Parse out the relative_url and other goodies from the configured URL // Parse out the relative_url and other goodies from the configured URL
const urlObject = url.parse(nconf.get('url')); const urlObject = url.parse(nconf.get('url'));