Skip to content

Commit fb431a9

Browse files
committed
Omit unused catch bindings in the function processRequest.
1 parent d998663 commit fb431a9

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
- Updated GitHub Actions CI config:
2121
- Updated the tested Node.js versions to v18, v20.
2222
- Removed the Node.js CLI option `--unhandled-rejections=throw` in the package script `tests` as it’s now the default for all supported Node.js versions.
23+
- Omit unused catch bindings in the function `processRequest`.
2324

2425
## 16.0.2
2526

processRequest.mjs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ export default function processRequest(
109109
case "operations":
110110
try {
111111
operations = JSON.parse(value);
112-
} catch (error) {
112+
} catch {
113113
return exit(
114114
createError(
115115
400,
@@ -143,7 +143,7 @@ export default function processRequest(
143143
let parsedMap;
144144
try {
145145
parsedMap = JSON.parse(value);
146-
} catch (error) {
146+
} catch {
147147
return exit(
148148
createError(
149149
400,
@@ -197,7 +197,7 @@ export default function processRequest(
197197

198198
try {
199199
operationsPath.set(path, map.get(fieldName));
200-
} catch (error) {
200+
} catch {
201201
return exit(
202202
createError(
203203
400,

0 commit comments

Comments
 (0)