feat(core): filter out null route
This commit is contained in:
parent
d2743c9d4f
commit
68aed429c5
|
|
@ -12,6 +12,5 @@ const app = require('../lib/app');
|
|||
const logger = require('../lib/utils/logger');
|
||||
|
||||
logger.info(`🎉 RSSHub is running! Cheers!`);
|
||||
logger.info('💖 Can you help keep this open source project alive? Please sponsor 👉 https://docs.rsshub.app/sponsor');
|
||||
|
||||
module.exports = handle(app);
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ const port = config.connect.port;
|
|||
const hostIPList = getLocalhostAddress();
|
||||
|
||||
logger.info(`🎉 RSSHub is running on port ${port}! Cheers!`);
|
||||
logger.info('💖 Can you help keep this open source project alive? Please sponsor 👉 https://docs.rsshub.app/sponsor');
|
||||
logger.info(`🔗 Local: 👉 http://localhost:${port}`);
|
||||
if (config.listenInaddrAny) {
|
||||
for (const ip of hostIPList) {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,9 @@ const middleware: MiddlewareHandler = async (ctx, next) => {
|
|||
|
||||
await next();
|
||||
|
||||
ctx.header('X-RSSHub-Route', ctx.req.routePath);
|
||||
if (ctx.req.routePath !== '/*') {
|
||||
ctx.header('X-RSSHub-Route', ctx.req.routePath);
|
||||
}
|
||||
|
||||
const data: Data = ctx.get('data');
|
||||
if (!data || ctx.res.headers.get('ETag')) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue