refactor: skip event report if not have any events

This commit is contained in:
moonrailgun 2024-07-20 18:01:27 +08:00
parent 1b89c3b5a8
commit f814691538

View File

@ -368,7 +368,15 @@ async function checkFeedEventsNotify(
},
});
sendFeedEventsNotify(channel, events);
if (events.length === 0) {
logger.info(
'Skip send events report because not include any events in this channel',
channel.id
);
return;
}
await sendFeedEventsNotify(channel, events);
},
{
concurrency: 5,