aboutsummaryrefslogtreecommitdiff
path: root/src/lib/extensions/discord.js/BushThreadMemberManager.d.ts
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-12-26 17:16:32 -0500
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-12-26 17:16:32 -0500
commitfc390ffc300334c396d9d06b0feaf8fbc6ed2814 (patch)
treea6282a74cf99033291ac7bc9de123ae273d528d2 /src/lib/extensions/discord.js/BushThreadMemberManager.d.ts
parent062435590980b87f5b054418ed88604e26358ae9 (diff)
downloadtanzanite-fc390ffc300334c396d9d06b0feaf8fbc6ed2814.tar.gz
tanzanite-fc390ffc300334c396d9d06b0feaf8fbc6ed2814.tar.bz2
tanzanite-fc390ffc300334c396d9d06b0feaf8fbc6ed2814.zip
documentation, bug fixes etc
Diffstat (limited to 'src/lib/extensions/discord.js/BushThreadMemberManager.d.ts')
-rw-r--r--src/lib/extensions/discord.js/BushThreadMemberManager.d.ts31
1 files changed, 30 insertions, 1 deletions
diff --git a/src/lib/extensions/discord.js/BushThreadMemberManager.d.ts b/src/lib/extensions/discord.js/BushThreadMemberManager.d.ts
index 7560c0e..dedf102 100644
--- a/src/lib/extensions/discord.js/BushThreadMemberManager.d.ts
+++ b/src/lib/extensions/discord.js/BushThreadMemberManager.d.ts
@@ -2,13 +2,42 @@ import type { BushClient, BushThreadChannel, BushThreadMember, BushThreadMemberR
import { CachedManager, type BaseFetchOptions, type Collection, type Snowflake, type UserResolvable } from 'discord.js';
import type { RawThreadMemberData } from 'discord.js/typings/rawDataTypes';
+/**
+ * Manages API methods for GuildMembers and stores their cache.
+ */
export class BushThreadMemberManager extends CachedManager<Snowflake, BushThreadMember, BushThreadMemberResolvable> {
public constructor(thread: BushThreadChannel, iterable?: Iterable<RawThreadMemberData>);
public declare readonly client: BushClient;
+
+ /**
+ * The thread this manager belongs to
+ */
public thread: BushThreadChannel;
+
+ /**
+ * Adds a member to the thread.
+ * @param member The member to add
+ * @param reason The reason for adding this member
+ */
public add(member: UserResolvable | '@me', reason?: string): Promise<Snowflake>;
+
+ /**
+ * Fetches member(s) for the thread from Discord, requires access to the `GUILD_MEMBERS` gateway intent.
+ * @param member The member to fetch. If `undefined`, all members in the thread are fetched, and will be
+ * cached based on `options.cache`. If boolean, this serves the purpose of `options.cache`.
+ * @param options Additional options for this fetch
+ */
public fetch(member?: UserResolvable, options?: BaseFetchOptions): Promise<BushThreadMember>;
- /** @deprecated Use `fetch(member, options)` instead. */
+
+ /**
+ * @deprecated Use `fetch(member, options)` instead.
+ */
public fetch(cache?: boolean): Promise<Collection<Snowflake, BushThreadMember>>;
+
+ /**
+ * Remove a user from the thread.
+ * @param id The id of the member to remove
+ * @param reason The reason for removing this member from the thread
+ */
public remove(id: Snowflake | '@me', reason?: string): Promise<Snowflake>;
}