mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 00:53:31 +01:00
feat(CommandInteractionResolvedData): access to "raw" resolved data (#6384)
Co-authored-by: Sugden <28943913+NotSugden@users.noreply.github.com>
This commit is contained in:
@@ -6,7 +6,7 @@ const { TypeError } = require('../errors');
|
||||
* A resolver for command interaction options.
|
||||
*/
|
||||
class CommandInteractionOptionResolver {
|
||||
constructor(client, options) {
|
||||
constructor(client, options, resolved) {
|
||||
/**
|
||||
* The client that instantiated this.
|
||||
* @name CommandInteractionOptionResolver#client
|
||||
@@ -55,6 +55,13 @@ class CommandInteractionOptionResolver {
|
||||
* @readonly
|
||||
*/
|
||||
Object.defineProperty(this, 'data', { value: Object.freeze([...options]) });
|
||||
|
||||
/**
|
||||
* The interaction resolved data
|
||||
* @name CommandInteractionOptionResolver#resolved
|
||||
* @type {Readonly<CommandInteractionResolvedData>}
|
||||
*/
|
||||
Object.defineProperty(this, 'resolved', { value: Object.freeze(resolved) });
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user