Skip to content

Commit d8e7f16

Browse files
committed
Fix @typescript-eslint/no-unused-vars
1 parent b687d5a commit d8e7f16

File tree

5 files changed

+5
-17
lines changed

5 files changed

+5
-17
lines changed

eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import tseslint from 'typescript-eslint';
33

44
export default tseslint.config([
55
{
6-
files: ['**/*.ts'],
6+
files: ['**/*.ts', '**/*.(c|m)?js'],
77
extends: [solanaConfig],
88
},
99
{

packages/errors/src/cli.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,7 @@ program
3232
.argument('[encodedContext]', 'encoded context to interpolate into the error message', encodedContext => {
3333
try {
3434
return decodeEncodedContext(encodedContext);
35-
} catch (
36-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
37-
e
38-
) {
35+
} catch {
3936
throw new InvalidArgumentError('Encoded context malformed');
4037
}
4138
})

packages/renderers-js-umi/test/_setup.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,7 @@ export function codeStringAsRegex(code: string) {
7676
async function normalizeCode(code: string) {
7777
try {
7878
code = await format(code, PRETTIER_OPTIONS);
79-
} catch (
80-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
81-
e
82-
) {
79+
} catch {
8380
// Ignore errors.
8481
}
8582
return code.trim();

packages/renderers-js/test/_setup.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,10 +105,7 @@ export function codeStringAsRegex(code: string) {
105105
async function normalizeCode(code: string) {
106106
try {
107107
code = await format(code, PRETTIER_OPTIONS);
108-
} catch (
109-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
110-
e
111-
) {
108+
} catch {
112109
// Ignore errors.
113110
}
114111
return code.trim();

packages/visitors/src/setInstructionAccountDefaultValuesVisitor.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,7 @@ export function setInstructionAccountDefaultValuesVisitor(rules: InstructionAcco
184184
fillDefaultPdaSeedValuesVisitor(instructionPath, linkables, true),
185185
),
186186
};
187-
} catch (
188-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
189-
error
190-
) {
187+
} catch {
191188
return account;
192189
}
193190
});

0 commit comments

Comments
 (0)