From 109a478a5bea65e17e7cbe9e3a846accd93be96f Mon Sep 17 00:00:00 2001 From: Fleny Date: Mon, 11 Aug 2025 19:43:54 +0200 Subject: [PATCH] fix(types): Sort teams.ts types (#4297) * Sort teams.ts types * Update packages/types/src/discord/teams.ts Co-authored-by: Link --------- Co-authored-by: Link --- packages/types/src/discord/teams.ts | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/packages/types/src/discord/teams.ts b/packages/types/src/discord/teams.ts index 8871c34c1..54e21e539 100644 --- a/packages/types/src/discord/teams.ts +++ b/packages/types/src/discord/teams.ts @@ -4,8 +4,15 @@ import type { DiscordUser } from './user.js' /* https://discord.com/developers/docs/topics/teams#team-member-roles-team-member-role-types */ export enum DiscordTeamMemberRole { - /** Owners are the most permissiable role, and can take destructive, irreversible actions like deleting the team itself. Teams are limited to 1 owner. */ - Owner = 'owner', + /** + * Owners are the most permissiable role, and can take destructive, irreversible actions like deleting the team itself. + * + * Teams are limited to 1 owner. + * + * @remarks + * The owner role is not represented in the role field on the team member object. Instead, the owner_user_id field on the team object should be used to identify which user has the owner role for the team. + */ + Owner = '', /** Admins have similar access as owners, except they cannot take destructive actions on the team or team-owned apps. */ Admin = 'admin', /** @@ -26,10 +33,10 @@ export interface DiscordTeam { id: string /** Members of the team */ members: DiscordTeamMember[] - /** User ID of the current team owner */ - owner_user_id: string /** Name of the team */ name: string + /** User ID of the current team owner */ + owner_user_id: string } /** https://discord.com/developers/docs/topics/teams#data-models-team-member-object */