fix: move upload_url to prestart so it is defined in upgrade scripts

v1.18.x
Baris Usakli 6 years ago
parent cead89f0ba
commit ad2d7a6991

@ -69,6 +69,7 @@ function loadConfig(configFile) {
nconf.set('base_templates_path', path.join(nconf.get('themes_path'), 'nodebb-theme-persona/templates'));
nconf.set('upload_path', path.resolve(nconf.get('base_dir'), nconf.get('upload_path')));
nconf.set('upload_url', '/assets/uploads');
if (nconf.get('url')) {
nconf.set('url_parsed', url.parse(nconf.get('url')));

@ -99,7 +99,6 @@ function setupConfigs() {
nconf.set('use_port', !!urlObject.port);
nconf.set('relative_path', relativePath);
nconf.set('port', nconf.get('PORT') || nconf.get('port') || urlObject.port || (nconf.get('PORT_ENV_VAR') ? nconf.get(nconf.get('PORT_ENV_VAR')) : false) || 4567);
nconf.set('upload_url', '/assets/uploads');
}
function printStartupInfo() {

Loading…
Cancel
Save