mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-18 12:33:30 +01:00
ci: fix typechecking in ci
This commit is contained in:
@@ -67,7 +67,7 @@
|
||||
"@favware/cliff-jumper": "^1.8.6",
|
||||
"@microsoft/api-extractor": "^7.29.2",
|
||||
"@types/jest": "^28.1.6",
|
||||
"@types/node": "^16.11.47",
|
||||
"@types/node": "^16.11.48",
|
||||
"@typescript-eslint/eslint-plugin": "^5.33.0",
|
||||
"@typescript-eslint/parser": "^5.33.0",
|
||||
"downlevel-dts": "^0.10.0",
|
||||
@@ -83,7 +83,7 @@
|
||||
"rollup-plugin-typescript2": "0.32.1",
|
||||
"tweetnacl": "^1.0.3",
|
||||
"typescript": "^4.7.4",
|
||||
"unbuild": "^0.8.4"
|
||||
"unbuild": "^0.8.8"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=16.9.0"
|
||||
|
||||
@@ -53,7 +53,7 @@ export enum VoiceConnectionStatus {
|
||||
*/
|
||||
export interface VoiceConnectionSignallingState {
|
||||
status: VoiceConnectionStatus.Signalling;
|
||||
subscription?: PlayerSubscription;
|
||||
subscription?: PlayerSubscription | undefined;
|
||||
adapter: DiscordGatewayAdapterImplementerMethods;
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ export enum VoiceConnectionDisconnectReason {
|
||||
*/
|
||||
export interface VoiceConnectionDisconnectedBaseState {
|
||||
status: VoiceConnectionStatus.Disconnected;
|
||||
subscription?: PlayerSubscription;
|
||||
subscription?: PlayerSubscription | undefined;
|
||||
adapter: DiscordGatewayAdapterImplementerMethods;
|
||||
}
|
||||
|
||||
@@ -128,7 +128,7 @@ export type VoiceConnectionDisconnectedState =
|
||||
export interface VoiceConnectionConnectingState {
|
||||
status: VoiceConnectionStatus.Connecting;
|
||||
networking: Networking;
|
||||
subscription?: PlayerSubscription;
|
||||
subscription?: PlayerSubscription | undefined;
|
||||
adapter: DiscordGatewayAdapterImplementerMethods;
|
||||
}
|
||||
|
||||
@@ -139,7 +139,7 @@ export interface VoiceConnectionConnectingState {
|
||||
export interface VoiceConnectionReadyState {
|
||||
status: VoiceConnectionStatus.Ready;
|
||||
networking: Networking;
|
||||
subscription?: PlayerSubscription;
|
||||
subscription?: PlayerSubscription | undefined;
|
||||
adapter: DiscordGatewayAdapterImplementerMethods;
|
||||
}
|
||||
|
||||
@@ -688,7 +688,7 @@ export class VoiceConnection extends EventEmitter {
|
||||
*
|
||||
* @param subscription - The removed subscription
|
||||
*/
|
||||
private onSubscriptionRemoved(subscription: PlayerSubscription) {
|
||||
protected onSubscriptionRemoved(subscription: PlayerSubscription) {
|
||||
if (this.state.status !== VoiceConnectionStatus.Destroyed && this.state.subscription === subscription) {
|
||||
this.state = {
|
||||
...this.state,
|
||||
|
||||
@@ -13,6 +13,6 @@ export class AudioPlayerError extends Error {
|
||||
super(error.message);
|
||||
this.resource = resource;
|
||||
this.name = error.name;
|
||||
this.stack = error.stack;
|
||||
this.stack = error.stack!;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -73,7 +73,7 @@ export class AudioResource<T = unknown> {
|
||||
/**
|
||||
* The audio player that the resource is subscribed to, if any.
|
||||
*/
|
||||
public audioPlayer?: AudioPlayer;
|
||||
public audioPlayer?: AudioPlayer | undefined;
|
||||
|
||||
/**
|
||||
* The playback duration of this audio resource, given in milliseconds.
|
||||
|
||||
@@ -10,7 +10,7 @@ export interface CreateVoiceConnectionOptions {
|
||||
* If true, debug messages will be enabled for the voice connection and its
|
||||
* related components. Defaults to false.
|
||||
*/
|
||||
debug?: boolean;
|
||||
debug?: boolean | undefined;
|
||||
|
||||
adapterCreator: DiscordGatewayAdapterCreator;
|
||||
}
|
||||
|
||||
@@ -81,7 +81,7 @@ export interface NetworkingReadyState {
|
||||
udp: VoiceUDPSocket;
|
||||
connectionOptions: ConnectionOptions;
|
||||
connectionData: ConnectionData;
|
||||
preparedPacket?: Buffer;
|
||||
preparedPacket?: Buffer | undefined;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -94,7 +94,7 @@ export interface NetworkingResumingState {
|
||||
udp: VoiceUDPSocket;
|
||||
connectionOptions: ConnectionOptions;
|
||||
connectionData: ConnectionData;
|
||||
preparedPacket?: Buffer;
|
||||
preparedPacket?: Buffer | undefined;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
{
|
||||
"extends": "../../tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"exactOptionalPropertyTypes": false
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user