Skip to content

Commit 7e21a94

Browse files
almeidxkodiakhq[bot]
authored andcommitted
feat(BaseInteraction): add attachmentSizeLimit (#10830)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
1 parent d0a535e commit 7e21a94

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

packages/discord.js/src/structures/BaseInteraction.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,12 @@ class BaseInteraction extends Base {
122122
* @type {?InteractionContextType}
123123
*/
124124
this.context = data.context ?? null;
125+
126+
/**
127+
* Attachment size limit in bytes
128+
* @type {number}
129+
*/
130+
this.attachmentSizeLimit = data.attachment_size_limit;
125131
}
126132

127133
/**

packages/discord.js/typings/index.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2102,6 +2102,7 @@ export class BaseInteraction<Cached extends CacheType = CacheType> extends Base
21022102
public locale: Locale;
21032103
public guildLocale: CacheTypeReducer<Cached, Locale>;
21042104
public entitlements: Collection<Snowflake, Entitlement>;
2105+
public attachmentSizeLimit: number;
21052106
public inGuild(): this is BaseInteraction<'raw' | 'cached'>;
21062107
public inCachedGuild(): this is BaseInteraction<'cached'>;
21072108
public inRawGuild(): this is BaseInteraction<'raw'>;

0 commit comments

Comments
 (0)