disgroove 2.2.1 → 2.2.2-dev.4aafdf4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,7 +28,6 @@ import type { Sticker, StickerPack } from "./types/sticker";
28
28
  import type { User, ApplicationRoleConnection, Connection } from "./types/user";
29
29
  import type { VoiceRegion, VoiceState } from "./types/voice";
30
30
  import type { Webhook } from "./types/webhook";
31
- import { VoiceConnectionManager } from "./voice";
32
31
  export interface ClientOptions {
33
32
  intents?: number | Array<number>;
34
33
  shardsCount?: number | "auto";
@@ -46,7 +45,6 @@ export declare class Client extends EventEmitter {
46
45
  user: User;
47
46
  guilds: Map<string, Guild>;
48
47
  application: Pick<Application, "id" | "flags">;
49
- voiceConnections: VoiceConnectionManager;
50
48
  constructor(token: string, options?: ClientOptions);
51
49
  /** https://discord.com/developers/docs/resources/channel#group-dm-add-recipient */
52
50
  addGroupRecipient(channelID: snowflake, userID: snowflake, options: {
@@ -9,7 +9,6 @@ const utils_1 = require("./utils");
9
9
  const rest_1 = require("./rest");
10
10
  const node_events_1 = __importDefault(require("node:events"));
11
11
  const gateway_1 = require("./gateway");
12
- const voice_1 = require("./voice");
13
12
  class Client extends node_events_1.default {
14
13
  token;
15
14
  intents;
@@ -22,7 +21,6 @@ class Client extends node_events_1.default {
22
21
  user;
23
22
  guilds;
24
23
  application;
25
- voiceConnections;
26
24
  constructor(token, options) {
27
25
  super();
28
26
  this.token = token;
@@ -39,7 +37,6 @@ class Client extends node_events_1.default {
39
37
  this.util = new utils_1.Util();
40
38
  this.guildShardMap = {};
41
39
  this.guilds = new Map();
42
- this.voiceConnections = new voice_1.VoiceConnectionManager();
43
40
  }
44
41
  /** https://discord.com/developers/docs/resources/channel#group-dm-add-recipient */
45
42
  addGroupRecipient(channelID, userID, options) {
@@ -2007,7 +2004,6 @@ class Client extends node_events_1.default {
2007
2004
  }
2008
2005
  /** https://discord.com/developers/docs/topics/gateway-events#update-voice-state */
2009
2006
  leaveVoiceChannel(guildID) {
2010
- this.voiceConnections.disconnect(guildID);
2011
2007
  this.shards.get(this.guildShardMap[guildID])?.updateVoiceState({
2012
2008
  guildID: guildID,
2013
2009
  channelID: null,
@@ -463,12 +463,6 @@ class Shard {
463
463
  break;
464
464
  case "VOICE_SERVER_UPDATE":
465
465
  {
466
- this.client.voiceConnections.connect(packet.d.endpoint, {
467
- serverID: packet.d.guild_id,
468
- userID: this.client.user.id,
469
- sessionID: this.sessionID,
470
- token: packet.d.token,
471
- });
472
466
  this.client.emit(constants_1.GatewayEvents.VoiceServerUpdate, {
473
467
  token: packet.d.token,
474
468
  guildID: packet.d.guild_id,
@@ -26,6 +26,5 @@ export * from "./types/user";
26
26
  export * from "./types/voice";
27
27
  export * from "./types/webhook";
28
28
  export * from "./utils";
29
- export * from "./voice";
30
29
  export * from "./Client";
31
30
  export * from "./constants";
package/dist/lib/index.js CHANGED
@@ -42,6 +42,5 @@ __exportStar(require("./types/user"), exports);
42
42
  __exportStar(require("./types/voice"), exports);
43
43
  __exportStar(require("./types/webhook"), exports);
44
44
  __exportStar(require("./utils"), exports);
45
- __exportStar(require("./voice"), exports);
46
45
  __exportStar(require("./Client"), exports);
47
46
  __exportStar(require("./constants"), exports);
@@ -13,8 +13,8 @@ export interface RawPoll {
13
13
  export interface RawPollCreateParams {
14
14
  question: RawPollMedia;
15
15
  answers: Array<RawPollAnswer>;
16
- duration: number;
17
- allow_multiselect: boolean;
16
+ duration?: number;
17
+ allow_multiselect?: boolean;
18
18
  layout_type?: LayoutType;
19
19
  }
20
20
  /** https://discord.com/developers/docs/resources/poll#poll-media-object-poll-media-object-structure */
@@ -49,8 +49,8 @@ export interface Poll {
49
49
  export interface PollCreateParams {
50
50
  question: PollMedia;
51
51
  answers: Array<PollAnswer>;
52
- duration: number;
53
- allowMultiselect: boolean;
52
+ duration?: number;
53
+ allowMultiselect?: boolean;
54
54
  layoutType?: LayoutType;
55
55
  }
56
56
  export interface PollMedia {
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "disgroove",
3
- "version": "2.2.1",
3
+ "version": "2.2.2-dev.4aafdf4",
4
4
  "description": "A module to interface with Discord",
5
5
  "main": "./dist/lib/index.js",
6
6
  "types": "./dist/lib/index.d.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "disgroove",
3
- "version": "2.2.1",
3
+ "version": "2.2.2-dev.4aafdf4",
4
4
  "description": "A module to interface with Discord",
5
5
  "main": "./dist/lib/index.js",
6
6
  "types": "./dist/lib/index.d.ts",