From 5f9ac3478089fb0af14fd9f906c55e0b49b2006c Mon Sep 17 00:00:00 2001 From: Elysia <71698422+aiko-chan-ai@users.noreply.github.com> Date: Wed, 27 Nov 2024 16:21:27 +0700 Subject: [PATCH] fix: remove deprecated ring method from User class and update return type in GroupDMChannel --- src/structures/GroupDMChannel.js | 2 +- src/structures/User.js | 13 ------------- typings/index.d.ts | 1 - 3 files changed, 1 insertion(+), 15 deletions(-) diff --git a/src/structures/GroupDMChannel.js b/src/structures/GroupDMChannel.js index 34bc546..ab0ac23 100644 --- a/src/structures/GroupDMChannel.js +++ b/src/structures/GroupDMChannel.js @@ -295,7 +295,7 @@ class GroupDMChannel extends Channel { /** * Ring the user's phone / PC (call) * @param {UserResolvable[]} [recipients] Array of recipients - * @returns {Promise} + * @returns {Promise} */ ring(recipients) { if (!recipients || !Array.isArray(recipients) || recipients.length == 0) { diff --git a/src/structures/User.js b/src/structures/User.js index d3d0daa..02c9118 100644 --- a/src/structures/User.js +++ b/src/structures/User.js @@ -479,19 +479,6 @@ class User extends Base { ); } - /** - * Ring the user's phone / PC (call) - * @returns {Promise} - * @deprecated - */ - ring() { - return this.client.api.channels(this.dmChannel.id).call.ring.post({ - data: { - recipients: [this.id], - }, - }); - } - /** * Send Friend Request to the user * @type {boolean} diff --git a/typings/index.d.ts b/typings/index.d.ts index b564c25..6831270 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -3497,7 +3497,6 @@ export class User extends PartialTextBasedChannel(Base) { public setNote(note: string | null | undefined): Promise; public toString(): UserMention; public getProfile(guildId?: Snowflake): Promise; - public ring(): Promise; public sendFriendRequest(): Promise; public deleteRelationship(): Promise; }