From ebb50160cb9234a7c7b714dccbe0acf4462a2a64 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Mon, 22 Aug 2016 18:16:09 -0400 Subject: [PATCH] wrap saving of url_parsed in conditional, since url isn't set during setup --- app.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app.js b/app.js index 74beb77d6e..7fdee397f9 100644 --- a/app.js +++ b/app.js @@ -104,7 +104,9 @@ function loadConfig() { nconf.set('core_templates_path', path.join(__dirname, 'src/views')); nconf.set('base_templates_path', path.join(nconf.get('themes_path'), 'nodebb-theme-persona/templates')); - nconf.set('url_parsed', url.parse(nconf.get('url'))); + if (nconf.get('url')) { + nconf.set('url_parsed', url.parse(nconf.get('url'))); + } }