所以,我有这样的代码:
Sorry, the editor said too much code so I got to move it to codeshare.
机器人已启动,可以接收消息并登录到控制台,但是,Logged in!
消息未登录到控制台,这意味着该机器人不是ready
,尽管该机器人可以接收命令并将其记录到控制台,它不会执行任何响应。请参阅下面的日志:
2020-07-07T14:39:44.000000+00:00 app[api]: Build started by user *censored*
2020-07-07T14:40:01.359235+00:00 heroku[worker.1]: Restarting
2020-07-07T14:40:01.373843+00:00 heroku[worker.1]: State changed from up to starting
2020-07-07T14:40:01.188192+00:00 app[api]: Release v8 created by user *censored*
2020-07-07T14:40:01.188192+00:00 app[api]: Deploy 5ad6fb20 by user *censored*
2020-07-07T14:40:02.483212+00:00 heroku[worker.1]: Stopping all processes with SIGTERM
2020-07-07T14:40:02.587261+00:00 heroku[worker.1]: Process exited with status 143
2020-07-07T14:40:02.000000+00:00 app[api]: Build succeeded
2020-07-07T14:40:04.535781+00:00 heroku[worker.1]: Starting process with command `node .`
2020-07-07T14:40:05.339920+00:00 heroku[worker.1]: State changed from starting to up
2020-07-07T14:40:12.340512+00:00 app[worker.1]: Iamnoot nho : about
这是不和谐窗口的屏幕截图:
编辑:Logged in!
消息问题是因为client.once('Ready', () => {
处的状态必须为ready
:D