diff --git a/src/api/web/index.js b/src/api/web/index.js index d9e35f18e..4bde9b753 100644 --- a/src/api/web/index.js +++ b/src/api/web/index.js @@ -42,7 +42,7 @@ module.exports = function(config, auth, storage) { const defaultTitle = 'Verdaccio'; let webPage = template .replace(/ToReplaceByVerdaccio/g, base) - .replace(/ToReplaceByTitle/g, _.isNil(config.web.title) ? defaultTitle : config.web.title) + .replace(/ToReplaceByTitle/g, _.get(config, 'web.title') ? config.web.title : defaultTitle) .replace(/(main.*\.js|style.*\.css)/g, `${base}/-/static/$1`); res.setHeader('Content-Type', 'text/html');