From 4ac91c61d08111ae4d49d1e64caf94e6e49832c8 Mon Sep 17 00:00:00 2001 From: Hyro Date: Thu, 21 Apr 2022 19:07:18 +0200 Subject: [PATCH] fix(Activity): platform type (#7805) --- packages/discord.js/src/structures/Presence.js | 10 +--------- packages/discord.js/typings/index.d.ts | 4 +--- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/packages/discord.js/src/structures/Presence.js b/packages/discord.js/src/structures/Presence.js index 1f6efb130d0f..d0a00d34ca67 100644 --- a/packages/discord.js/src/structures/Presence.js +++ b/packages/discord.js/src/structures/Presence.js @@ -136,14 +136,6 @@ class Presence extends Base { } } -/** - * The platform of this activity: - * * **`desktop`** - * * **`samsung`** - playing on Samsung Galaxy - * * **`xbox`** - playing on Xbox Live - * @typedef {string} ActivityPlatform - */ - /** * Represents an activity that is part of a user's presence. */ @@ -219,7 +211,7 @@ class Activity { /** * The platform the game is being played on - * @type {?ActivityPlatform} + * @type {?string} */ this.platform = data.platform ?? null; diff --git a/packages/discord.js/typings/index.d.ts b/packages/discord.js/typings/index.d.ts index 57db5e9e3343..81091b8b7b07 100644 --- a/packages/discord.js/typings/index.d.ts +++ b/packages/discord.js/typings/index.d.ts @@ -199,7 +199,7 @@ export class Activity { id: string | null; size: [number, number]; } | null; - public platform: ActivityPlatform | null; + public platform: string | null; public sessionId: string | null; public state: string | null; public syncId: string | null; @@ -3426,8 +3426,6 @@ export interface ActivityOptions { shardId?: number | readonly number[]; } -export type ActivityPlatform = 'desktop' | 'samsung' | 'xbox'; - export interface AddGuildMemberOptions { accessToken: string; nick?: string;