This repository has been archived by the owner on Aug 15, 2023. It is now read-only.
Replies: 1 comment 5 replies
-
for n in list:
for n in weiboNews:
boardcast() |
Beta Was this translation helpful? Give feedback.
5 replies
Answer selected by
Arondight
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
我最近试着写另一个游戏的新闻推送,结果今天测试的时候同一条消息推了九遍……想问一下广播的循环体是怎么样的
https://github.com/Mark9804/Adachi-BOT-fork/blob/77f61965bd977a9f0c492f04651e395c6e264b97/src/jobs/ak-news.js#L123-L130
需要广播的新闻 array 如下
测试循环条件
输出
>> 9
但是尝试
bot.boardcast
的时候,同一条内容输出了 9 次,感觉很迷惑Console 输出: https://gist.github.com/Mark9804/a0edc80104510d56993ce767caaa4e54
Beta Was this translation helpful? Give feedback.
All reactions