From 28a50bfe081ceedd6aac0a94f93a098eba2ae2bb Mon Sep 17 00:00:00 2001 From: "Juan Picado @jotadeveloper" Date: Tue, 19 Feb 2019 07:04:39 +0100 Subject: [PATCH] chore: fix router issue --- src/api/web/index.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/api/web/index.js b/src/api/web/index.js index 05ee3c877..559cdda8c 100644 --- a/src/api/web/index.js +++ b/src/api/web/index.js @@ -12,7 +12,6 @@ import express from 'express'; import { combineBaseUrl, getWebProtocol } from '../../lib/utils'; import Search from '../../lib/search'; import { HEADERS, HTTP_STATUS, WEB_TITLE } from '../../lib/constants'; -import { spliceURL } from '../../utils/string'; const { securityIframe } = require('../middleware'); /* eslint new-cap:off */ @@ -66,16 +65,10 @@ module.exports = function(config, auth, storage) { res.send(webPage); } - router.get('/-/web/:pkg', function(req, res) { + router.get('/-/web/:section/*', function(req, res) { renderHTML(req, res); }); - router.get('/-/verdaccio/logo', function(req, res) { - const installPath = _.get(config, 'url_prefix', ''); - - res.send(_.get(config, 'web.logo') || spliceURL(installPath, '/-/static/logo.png')); - }); - router.get('/', function(req, res) { renderHTML(req, res); });