Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(RoleTagData): add guildConnections #9366

Merged
merged 4 commits into from Apr 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/discord.js/src/structures/Role.js
Expand Up @@ -109,6 +109,7 @@ class Role extends Base {
* @property {true} [premiumSubscriberRole] Whether this is the guild's premium subscription role
* @property {Snowflake} [subscriptionListingId] The id of this role's subscription SKU and listing
* @property {true} [availableForPurchase] Whether this role is available for purchase
* @property {true} [guildConnections] Whether this role is a guild's linked role
*/
this.tags = data.tags ? {} : null;
if (data.tags) {
Expand All @@ -127,6 +128,9 @@ class Role extends Base {
if ('available_for_purchase' in data.tags) {
this.tags.availableForPurchase = true;
}
if ('guild_connections' in data.tags) {
this.tags.guildConnections = true;
}
}
}

Expand Down
1 change: 1 addition & 0 deletions packages/discord.js/typings/index.d.ts
Expand Up @@ -6105,6 +6105,7 @@ export interface RoleTagData {
premiumSubscriberRole?: true;
subscriptionListingId?: Snowflake;
availableForPurchase?: true;
guildConnections?: true;
}

export interface SetChannelPositionOptions {
Expand Down