Skip to content

Commit

Permalink
fix: 推送空消息
Browse files Browse the repository at this point in the history
  • Loading branch information
shanmiteko committed Oct 20, 2021
1 parent e298970 commit e8b9e05
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/check.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ async function isMe() {
if (UnreadAtNum > 0) {
log.info('中奖检测', '<-- 正在检查at');
const MyAtInfo = await bili.getMyAtInfo();
desp += '## [at]检测结果\n\n'
MyAtInfo.forEach(async AtInfo => {
const { at_time, up_uname, business, source_content, url } = AtInfo
desp += '## [at]检测结果\n\n'
desp += '----------------------------------------------------------------\n\n'
desp += `发生时间: ${new Date(at_time * 1000).toLocaleString()}\n\n`
desp += `用户: ${up_uname}\n\n`
Expand All @@ -42,6 +42,7 @@ async function isMe() {
bili.updateSessionStatus(talker_id, type, msg_seqno);
await delay(update_session_wait);
if (judge(content, notice_key_words)) {
desp += '## 私信检测结果\n\n'
desp += '----------------------------------------------------------------\n\n'
desp += `发生时间: ${new Date(timestamp * 1000).toLocaleString()}\n\n`
desp += `用户: ${sender_uid}\n\n`
Expand All @@ -59,7 +60,6 @@ async function isMe() {
}
}
}
desp += '## 私信检测结果\n\n'
if (follow_unread) {
log.info('中奖检测', '<-- 正在检查已关注者的私信')
await check(1)
Expand Down

0 comments on commit e8b9e05

Please sign in to comment.