Skip to content

Commit

Permalink
devdeps: eslint@6.8.0->7.32.0 (#130)
Browse files Browse the repository at this point in the history
* devdeps: eslint@6.8.0->7.32.0

- CVE-2021-3807 / GHSA-93q8-gq69-wqmw

* lint:fix
  • Loading branch information
legobeat authored Apr 24, 2023
1 parent 2905a94 commit 0bda312
Show file tree
Hide file tree
Showing 3 changed files with 1,257 additions and 783 deletions.
6 changes: 3 additions & 3 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ interface EventMap {
[k: string]: Handler | Handler[] | undefined;
}

function safeApply<T, A extends any[]> (handler: (this: T, ...args: A) => void, context: T, args: A): void {
function safeApply<T, A extends any[]>(handler: (this: T, ..._args: A) => void, context: T, args: A): void {
try {
Reflect.apply(handler, context, args);
} catch (err) {
Expand All @@ -16,7 +16,7 @@ function safeApply<T, A extends any[]> (handler: (this: T, ...args: A) => void,
}
}

function arrayClone<T> (arr: T[]): T[] {
function arrayClone<T>(arr: T[]): T[] {
const n = arr.length;
const copy = new Array(n);
for (let i = 0; i < n; i += 1) {
Expand All @@ -26,7 +26,7 @@ function arrayClone<T> (arr: T[]): T[] {
}

export default class SafeEventEmitter extends EventEmitter {
emit (type: string, ...args: any[]): boolean {
emit(type: string, ...args: any[]): boolean {
let doError = type === 'error';

const events: EventMap = (this as any)._events;
Expand Down
13 changes: 7 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,15 @@
"author": "",
"license": "ISC",
"devDependencies": {
"@metamask/eslint-config": "^3.1.0",
"@metamask/eslint-config": "^5.0.0",
"@types/jest": "^26.0.20",
"@types/node": "^14.14.21",
"@typescript-eslint/eslint-plugin": "^2.20.0",
"@typescript-eslint/parser": "^2.16.0",
"eslint": "^6.8.0",
"eslint-plugin-import": "^2.20.1",
"eslint-plugin-jest": "^23.6.0",
"@typescript-eslint/eslint-plugin": "^4.33.0",
"@typescript-eslint/parser": "^4.33.0",
"eslint": "^7.32.0",
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-jest": "^24.1.3",
"eslint-plugin-node": "^11.1.0",
"jest": "^26.4.2",
"ts-jest": "^26.4.0",
"typescript": "^4.0.5"
Expand Down
Loading

0 comments on commit 0bda312

Please sign in to comment.