caching - 错误无法读取 discord.js 中未定义的属性“缓存”
问题描述
我尝试将其更改client.channels
为client.channel
client.channelId
仍然没有运气,试图解决这个问题已经有一段时间了,请帮忙。我正在使用 discord.js v13.1.0 顺便说一句
const filter = (m) => m.author.id === message.author.id;
const appStart = await message.author.send({ content: questions[collectCounter++] });
const channel = appStart.channel;
const collector = channel.createMessageCollector(filter);
collector.on("collect", () => {
if (collectCounter < questions.length){
channel.send(quesstions[collectCounter++]);
} else {
channel.send("Your profile has been succesfully updated")
Collector.stop("fulfilled");
}
});
const femalechannel = client.channels.cache.get("881098900600152084");
const malechannel = client.channels.cache.get("881098930711035924");
解决方案
推荐阅读
- r - 要使用 depmixs4 找到最适合的 HMM,我需要执行多少次 set.seed 和 fit.mod?
- python - Tkinter StringVar() 显示空白
- azure - 在 ASE ILB 中创建同名的 Azure Web 应用程序,不会警告资源已存在,也不会创建 2 个同名的 Web 应用程序
- curl - QueryDict 不会从 PATCH 请求中拆分 json 数据
- spring-boot - 在 SpringBoot 中使用 @ConfigurationProperties 设置超时
- angular - 将 LoginGuard 的输出设置为 false
- javascript - React- Lodash without() 方法在状态更改后呈现为空?
- android-studio - Android Studio 不接受 Android SDK 位置
- php - 如何在查询中添加 where between?
- python - 一起训练多个 tensorflow NN