aboutsummaryrefslogtreecommitdiff
path: root/src/lib/extensions/discord.js/other.ts
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-03-08 19:37:57 -0500
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-03-08 19:37:57 -0500
commitb86a05f4b21c62e18bf669e00646b715a409bdb0 (patch)
tree6d3623c45fd321ade5f8bbf6de37385f43123759 /src/lib/extensions/discord.js/other.ts
parent57e47b8b84dee001c65c1ab43833c09fef056a4b (diff)
downloadtanzanite-b86a05f4b21c62e18bf669e00646b715a409bdb0.tar.gz
tanzanite-b86a05f4b21c62e18bf669e00646b715a409bdb0.tar.bz2
tanzanite-b86a05f4b21c62e18bf669e00646b715a409bdb0.zip
feat: misc changes for extentions
Diffstat (limited to 'src/lib/extensions/discord.js/other.ts')
-rw-r--r--src/lib/extensions/discord.js/other.ts23
1 files changed, 10 insertions, 13 deletions
diff --git a/src/lib/extensions/discord.js/other.ts b/src/lib/extensions/discord.js/other.ts
index e4bc10b..7705c18 100644
--- a/src/lib/extensions/discord.js/other.ts
+++ b/src/lib/extensions/discord.js/other.ts
@@ -19,7 +19,8 @@ import type {
BushVoiceChannel,
PartialBushDMChannel
} from '#lib';
-import type { ChannelType, Collection, Message, Snowflake } from 'discord.js';
+import { APIMessage } from 'discord-api-types/v9';
+import type { CacheType, CacheTypeReducer, ChannelType, Collection, Message, Snowflake } from 'discord.js';
/**
* Data that resolves to give a ThreadMember object.
@@ -150,16 +151,12 @@ export interface BushFetchedThreads {
hasMore?: boolean;
}
-// for reverse key mapping
-
-/**
- * https://discord.com/developers/docs/interactions/receiving-and-responding#interaction-object-interaction-type
- */
-export enum BushInteractionType {
- Ping = 1,
- ApplicationCommand = 2,
- MessageComponent = 3,
- ApplicationCommandAutocomplete = 4
-}
-
export type BushNonCategoryGuildBasedChannel = Exclude<BushGuildBasedChannel, BushCategoryChannel>;
+
+export type BushGuildCacheMessage<Cached extends CacheType> = CacheTypeReducer<
+ Cached,
+ BushMessage<true>,
+ APIMessage,
+ BushMessage | APIMessage,
+ BushMessage | APIMessage
+>;