Add some UserFlags (Undocument)

This commit is contained in:
March 7th
2022-06-04 14:00:20 +07:00
parent 26f56f1650
commit b0172e6b51
3 changed files with 20 additions and 1 deletions

View File

@@ -231,6 +231,9 @@ class ThreadManager extends CachedManager {
* @returns {Promise<FetchedThreads>}
*/
async fetchActive(cache = true) {
if (!this.client.user.bot) {
throw new Error('INVALID_USER_METHOD: User accounts cannot use this method\nI will fix it .-.');
}
const raw = await this.client.api.guilds(this.channel.guild.id).threads.active.get();
return this.constructor._mapThreads(raw, this.client, { parent: this.channel, cache });
}