Skip to content

Commit

Permalink
Bump deps and make my editor happy
Browse files Browse the repository at this point in the history
  • Loading branch information
PapiOphidian committed Dec 21, 2024
1 parent 55f315d commit ca2f23f
Show file tree
Hide file tree
Showing 6 changed files with 408 additions and 436 deletions.
1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

3 changes: 3 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
"ignores": ["node_modules", "docs", "dist"]
}
32 changes: 16 additions & 16 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
"types": "./dist/index.d.ts",
"scripts": {
"prepublishOnly": "yarn compile",
"lint": "eslint --fix --ext ts src",
"test": "eslint --ext ts src",
"lint": "eslint . -c eslint.config.js --fix",
"test": "eslint . -c eslint.config.js",
"compile": "tsc -p .",
"watch": "tsc -p . -w",
"docs": "typedoc"
"docs": "typedoc --sort static-first --sort alphabetical"
},
"repository": {
"type": "git",
Expand All @@ -35,26 +35,26 @@
"homepage": "https://github.com/MrJacz/lavacord#readme",
"dependencies": {
"lavalink-types": "^2.1.1",
"undici": "^6.0.1",
"ws": "^8.15.0"
"undici": "^7.2.0",
"ws": "^8.18.0"
},
"devDependencies": {
"@types/node": "^20.11.24",
"@types/ws": "^8.5.10",
"@typescript-eslint/eslint-plugin": "^7.1.0",
"@typescript-eslint/parser": "^7.1.0",
"eslint": "^8.57.0",
"@types/node": "^22.10.2",
"@types/ws": "^8.5.13",
"@typescript-eslint/eslint-plugin": "^8.18.1",
"@typescript-eslint/parser": "^8.18.1",
"eslint": "^9.17.0",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-promise": "^6.1.1",
"typedoc": "^0.25.9",
"typescript": "^5.3.3"
"eslint-plugin-promise": "^7.2.1",
"typedoc": "^0.27.5",
"typescript": "^5.7.2"
},
"optionalDependencies": {
"discord.js": "14.x",
"eris": "0.17.x",
"eris": "0.18.x",
"detritus-client": "0.16.x",
"cloudstorm": "0.10.x",
"oceanic.js": "1.9.0"
"cloudstorm": "0.11.x",
"oceanic.js": "1.11.x"
},
"files": [
"dist",
Expand Down
4 changes: 3 additions & 1 deletion src/lib/LavalinkNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,9 @@ export class LavalinkNode {
const ws = new WebSocket(`ws://${this.host}:${this.port}/v${numMajor}/websocket`, { headers });

const onEvent = (event: unknown): void => {
// @ts-expect-error removeAllListeners still exists
ws.removeAllListeners();
reject(event);
reject(event instanceof Error ? event : new Error("Premature close"));
};

const onOpen = (): void => {
Expand Down Expand Up @@ -253,6 +254,7 @@ export class LavalinkNode {
*/
private reconnect(): void {
this._reconnect = setTimeout(() => {
// @ts-expect-error removeAllListeners still exists
this.ws!.removeAllListeners();
this.ws = null;

Expand Down
4 changes: 2 additions & 2 deletions src/lib/Manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export class Manager extends EventEmitter {
/**
* The Player the manager will use when creating new Players
*/
private Player: typeof Player = Player;
private readonly Player: typeof Player = Player;
/**
* An Set of all the expecting connections guild id's
*/
private expecting = new Set<string>();
private readonly expecting = new Set<string>();

/**
* The constructor of the Manager
Expand Down
Loading

0 comments on commit ca2f23f

Please sign in to comment.