我试图扫描嵌入的内部,就像我最后一个问题,我设法修复了错误,但现在的代码只是不会扫描字数组的内部。代码:https://pastebin.com/jeyaHKhK
-------------------------------
There is no error just the line
if (message.embeds[0].description.includes("Enjoy the videos and music you love on YouTube.")){
-------------------------------
Will not scan inside an array and will only scan if it has quotations like this ^
问题是你并没有循环遍历数组,你只是在循环数组的长度。通过查看您的Pastebin:
,应该可以使其工作。if (message.embeds[j].description.includes("Enjoy the videos and music you love on YouTube.")){
注意我替换了"0"从索引"j"变量,现在意味着他循环遍历数组中的所有项。