diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-12-13 20:22:20 -0500 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-12-13 20:22:20 -0500 |
commit | 9f705a0e5a90177784d45d20200dbaa46a569e78 (patch) | |
tree | 15390ea91d0ff3c3912be2b8cbe354f8703bb652 /src/lib/extensions | |
parent | 2d6bb50ce8c979e543f0d2831b3db9d8644be477 (diff) | |
download | tanzanite-9f705a0e5a90177784d45d20200dbaa46a569e78.tar.gz tanzanite-9f705a0e5a90177784d45d20200dbaa46a569e78.tar.bz2 tanzanite-9f705a0e5a90177784d45d20200dbaa46a569e78.zip |
fix more bugs
Diffstat (limited to 'src/lib/extensions')
4 files changed, 26 insertions, 7 deletions
diff --git a/src/lib/extensions/discord.js/BushButtonInteraction.ts b/src/lib/extensions/discord.js/BushButtonInteraction.ts index 9e62d46..18d6b35 100644 --- a/src/lib/extensions/discord.js/BushButtonInteraction.ts +++ b/src/lib/extensions/discord.js/BushButtonInteraction.ts @@ -1,10 +1,16 @@ -import type { BushClient, BushGuild, BushGuildMember, BushTextBasedChannels, BushUser } from '#lib'; +import type { BushClient, BushGuild, BushGuildMember, BushGuildTextBasedChannel, BushTextBasedChannels, BushUser } from '#lib'; import type { APIInteractionGuildMember } from 'discord-api-types/v9'; import { ButtonInteraction, type CacheType, type CacheTypeReducer } from 'discord.js'; import type { RawMessageButtonInteractionData } from 'discord.js/typings/rawDataTypes'; export class BushButtonInteraction<Cached extends CacheType = CacheType> extends ButtonInteraction<Cached> { - public declare readonly channel: CacheTypeReducer<Cached, BushTextBasedChannels | null>; + public declare readonly channel: CacheTypeReducer< + Cached, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushTextBasedChannels | null + >; public declare readonly guild: CacheTypeReducer<Cached, BushGuild, null>; public declare member: CacheTypeReducer<Cached, BushGuildMember, APIInteractionGuildMember>; public declare user: BushUser; diff --git a/src/lib/extensions/discord.js/BushChannel.d.ts b/src/lib/extensions/discord.js/BushChannel.d.ts index 9a78b9a..497c33a 100644 --- a/src/lib/extensions/discord.js/BushChannel.d.ts +++ b/src/lib/extensions/discord.js/BushChannel.d.ts @@ -7,7 +7,8 @@ export class BushChannel extends Channel { public constructor(client: BushClient, data?: RawChannelData, immediatePatch?: boolean); public readonly createdAt: Date; public readonly createdTimestamp: number; - public deleted: boolean; + public get deleted(): boolean; + public set deleted(value: boolean); public id: Snowflake; public readonly partial: false; public type: keyof typeof ChannelTypes; diff --git a/src/lib/extensions/discord.js/BushCommandInteraction.ts b/src/lib/extensions/discord.js/BushCommandInteraction.ts index b61ec9b..174fd9c 100644 --- a/src/lib/extensions/discord.js/BushCommandInteraction.ts +++ b/src/lib/extensions/discord.js/BushCommandInteraction.ts @@ -10,14 +10,20 @@ import type { import type { APIInteractionGuildMember } from 'discord-api-types/v9'; import { CommandInteraction, type CacheType, type CacheTypeReducer, type Invite, type Snowflake } from 'discord.js'; import type { RawCommandInteractionData } from 'discord.js/typings/rawDataTypes'; -import { BushTextBasedChannels, type BushClient } from '../discord-akairo/BushClient'; +import { BushGuildTextBasedChannel, BushTextBasedChannels, type BushClient } from '../discord-akairo/BushClient'; export type BushGuildResolvable = BushGuild | BushGuildChannel | BushGuildMember | BushGuildEmoji | Invite | BushRole | Snowflake; export class BushCommandInteraction<Cached extends CacheType = CacheType> extends CommandInteraction<Cached> { public declare readonly client: BushClient; public declare readonly command: BushApplicationCommand | BushApplicationCommand<{ guild: BushGuildResolvable }> | null; - public declare readonly channel: CacheTypeReducer<Cached, BushTextBasedChannels | null>; + public declare readonly channel: CacheTypeReducer< + Cached, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushTextBasedChannels | null + >; public declare readonly guild: CacheTypeReducer<Cached, BushGuild, null>; public declare member: CacheTypeReducer<Cached, BushGuildMember, APIInteractionGuildMember>; public declare user: BushUser; diff --git a/src/lib/extensions/discord.js/BushSelectMenuInteraction.ts b/src/lib/extensions/discord.js/BushSelectMenuInteraction.ts index 6b33c20..d33ddd3 100644 --- a/src/lib/extensions/discord.js/BushSelectMenuInteraction.ts +++ b/src/lib/extensions/discord.js/BushSelectMenuInteraction.ts @@ -1,10 +1,16 @@ -import type { BushClient, BushGuild, BushGuildMember, BushTextBasedChannels, BushUser } from '#lib'; +import type { BushClient, BushGuild, BushGuildMember, BushGuildTextBasedChannel, BushTextBasedChannels, BushUser } from '#lib'; import type { APIInteractionGuildMember } from 'discord-api-types/v9'; import { SelectMenuInteraction, type CacheType, type CacheTypeReducer } from 'discord.js'; import type { RawMessageSelectMenuInteractionData } from 'discord.js/typings/rawDataTypes'; export class BushSelectMenuInteraction<Cached extends CacheType = CacheType> extends SelectMenuInteraction<Cached> { - public declare readonly channel: CacheTypeReducer<Cached, BushTextBasedChannels | null>; + public declare readonly channel: CacheTypeReducer< + Cached, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushGuildTextBasedChannel | null, + BushTextBasedChannels | null + >; public declare readonly guild: CacheTypeReducer<Cached, BushGuild, null>; public declare member: CacheTypeReducer<Cached, BushGuildMember, APIInteractionGuildMember>; public declare user: BushUser; |