feat(core): filter out null route

This commit is contained in:
DIYgod 2025-05-14 20:25:45 +08:00
parent d2743c9d4f
commit 68aed429c5
No known key found for this signature in database
3 changed files with 3 additions and 3 deletions

View File

@ -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);

View File

@ -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) {

View File

@ -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')) {